/** * Returns the 'hasOnlySubstanceUnits' for this {@link Species}. * * @return the 'hasOnlySubstanceUnits' for this {@link Species}. */ public boolean hasOnlySubstanceUnits() { return isSetHasOnlySubstanceUnits() ? hasOnlySubstanceUnits : false; }
@Override public int hashCode() { final int prime = 997; int hashCode = super.hashCode(); hashCode += prime * Boolean.valueOf(amount).hashCode(); if (isSetBoundaryCondition()) { hashCode += prime * boundaryCondition.hashCode(); } if (isSetHasOnlySubstanceUnits()) { hashCode += prime * hasOnlySubstanceUnits.hashCode(); } if (isSetCharge()) { hashCode += prime * charge.hashCode(); } if (isSetSpeciesType()) { hashCode += prime * getSpeciesType().hashCode(); } if (isSetCompartment()) { hashCode += prime * getCompartment().hashCode(); } if (isSetSpatialSizeUnits()) { hashCode += prime * getSpatialSizeUnits().hashCode(); } if (isSetConversionFactor()) { hashCode += prime * getConversionFactor().hashCode(); } return hashCode; }
if (getLevel() > 2 && !isSetHasOnlySubstanceUnits()) { if (isSetHasOnlySubstanceUnits() && !hasOnlySubstanceUnits()) {
@Override public boolean check(ValidationContext ctx, Species c) { // id 'compartment', 'hasOnlySubstanceUnits', 'boundaryCondition'and constant are mandatory attributes if (!c.isSetId() || !c.isSetConstant() || !c.isSetHasOnlySubstanceUnits() || !c.isSetBoundaryCondition() || !c.isSetCompartment()) { return false; } return super.check(ctx, c); } };
attributes.put(TreeNodeChangeEvent.substanceUnits, getSubstanceUnits()); if (isSetHasOnlySubstanceUnits()) { attributes.put(TreeNodeChangeEvent.hasOnlySubstanceUnits, Boolean.toString(getHasOnlySubstanceUnits()));
setSubstanceUnits(new String(species.getSubstanceUnits())); if (species.isSetHasOnlySubstanceUnits()) { setHasOnlySubstanceUnits(new Boolean( species.getHasOnlySubstanceUnits()));
SBase sbase = m.getSBaseById(id); if (sbase instanceof Species && ((Species) sbase).isSetHasOnlySubstanceUnits() && !((Species) sbase).hasOnlySubstanceUnits())
equals &= s.getBoundaryCondition() == getBoundaryCondition(); equals &= s.isSetHasOnlySubstanceUnits() == isSetHasOnlySubstanceUnits(); if (equals && isSetHasOnlySubstanceUnits()) { equals &= s.getHasOnlySubstanceUnits() == getHasOnlySubstanceUnits();
if ((isSetHasOnlySubstanceUnits() || getLevel() < 3) && !hasOnlySubstanceUnits) { Compartment compartment = getCompartmentInstance();