/** * Creates a new {@link Input} instance. * * @param id the id to be set. * @param name the name to be set. * @param level the SBML level * @param version the SBML version */ public Input(String id, String name, int level, int version) { super(id, name, level, version); if (getLevelAndVersion().compareTo(Integer.valueOf(3), Integer.valueOf(1)) < 0) { throw new LevelVersionError(getElementName(), level, version); } initDefaults(); }
/** * Creates a new {@link Transition} instance. * * @param id the id * @param name the name * @param level the SBML level * @param version the SBML version */ public Transition(String id, String name, int level, int version) { super(id, name, level, version); if (getLevelAndVersion().compareTo(Integer.valueOf(3), Integer.valueOf(1)) < 0) { throw new LevelVersionError(getElementName(), level, version); } initDefaults(); }
/** * Creates a new {@link Output} instance. * * @param id the id * @param name the name * @param level the SBML level * @param version the SBML version */ public Output(String id, String name, int level, int version) { super(id, name, level, version); if (getLevelAndVersion().compareTo(Integer.valueOf(3), Integer.valueOf(1)) < 0) { throw new LevelVersionError(getElementName(), level, version); } initDefaults(); }
/** * Creates a ExternalModelDefinition instance with an id, name, level, and version. * * @param id the id * @param name the name * @param level the SBML level * @param version the SBML version */ public ExternalModelDefinition(String id, String name, int level, int version) { super(id, name, level, version); if (getLevelAndVersion().compareTo(Integer.valueOf(CompConstants.MIN_SBML_LEVEL), Integer.valueOf(CompConstants.MIN_SBML_VERSION)) < 0) { throw new LevelVersionError(getElementName(), level, version); } initDefaults(); }
/** * Creates a SpeciesFeatureChange instance with an id, name, level, and version. * * @param id the identifier for this element. * @param name a human-readable name for this element that can be used for display purposes. * @param level the SBML Level * @param version the SBML Version */ public SpeciesFeatureChange(String id, String name, int level, int version) { super(id, name, level, version); if (getLevelAndVersion().compareTo( Integer.valueOf(MultiConstants.MIN_SBML_LEVEL), Integer.valueOf(MultiConstants.MIN_SBML_VERSION)) < 0) { throw new LevelVersionError(getElementName(), level, version); } initDefaults(); }
/** * Creates a SpeciesFeature instance with an id, name, level, and version. * * @param id the identifier for this element. * @param name a human-readable name for this element that can be used for display purposes. * @param level the SBML Level * @param version the SBML Version */ public SpeciesFeature(String id, String name, int level, int version) { super(id, name, level, version); if (getLevelAndVersion().compareTo( Integer.valueOf(MultiConstants.MIN_SBML_LEVEL), Integer.valueOf(MultiConstants.MIN_SBML_VERSION)) < 0) { throw new LevelVersionError(getElementName(), level, version); } initDefaults(); }
/** * Creates a {@link ChangedMath} instance with an id, name, level, and version. * * @param id * @param name * @param level * @param version */ public ChangedMath(String id, String name, int level, int version) { super(id, name, level, version); if (getLevelAndVersion().compareTo( Integer.valueOf(ReqConstants.MIN_SBML_LEVEL), Integer.valueOf(ReqConstants.MIN_SBML_VERSION)) < 0) { throw new LevelVersionError(getElementName(), level, version); } initDefaults(); }
/** * Creates a SpeciesTypeInstance instance with an id, name, level, and version. * * @param id the identifier for this element. * @param name a human-readable name for this element that can be used for display purposes. * @param level the SBML Level * @param version the SBML Version */ public SpeciesTypeInstance(String id, String name, int level, int version) { super(id, name, level, version); if (getLevelAndVersion().compareTo( Integer.valueOf(MultiConstants.MIN_SBML_LEVEL), Integer.valueOf(MultiConstants.MIN_SBML_VERSION)) < 0) { throw new LevelVersionError(getElementName(), level, version); } initDefaults(); }
/** * Creates a MultiSpeciesType instance with an id, name, level, and version. * * @param id the identifier for this element. * @param name a human-readable name for this element that can be used for display purposes. * @param level the SBML Level * @param version the SBML Version */ public MultiSpeciesType(String id, String name, int level, int version) { super(id, name, level, version); if (getLevelAndVersion().compareTo( Integer.valueOf(MultiConstants.MIN_SBML_LEVEL), Integer.valueOf(MultiConstants.MIN_SBML_VERSION)) < 0) { throw new LevelVersionError(getElementName(), level, version); } initDefaults(); }
/** * Creates a Deletion instance with an id, name, level, and version. * * @param id the id * @param name the name * @param level the SBML level * @param version the SBML version */ public Deletion(String id, String name, int level, int version) { super(id, name, level, version); if (getLevelAndVersion().compareTo( Integer.valueOf(CompConstants.MIN_SBML_LEVEL), Integer.valueOf(CompConstants.MIN_SBML_VERSION)) < 0) { throw new LevelVersionError(getElementName(), level, version); } initDefaults(); }
/** * Creates a Port instance with an id, name, level, and version. * * @param id the id * @param name the name * @param level the SBML level * @param version the SBML version */ public Port(String id, String name, int level, int version) { super(id, name, level, version); if (getLevelAndVersion().compareTo( Integer.valueOf(CompConstants.MIN_SBML_LEVEL), Integer.valueOf(CompConstants.MIN_SBML_VERSION)) < 0) { throw new LevelVersionError(getElementName(), level, version); } initDefaults(); }
/** * Creates a InSpeciesTypeBond instance with an id, name, level, and version. * * @param id the identifier for this element. * @param name a human-readable name for this element that can be used for display purposes. * @param level the SBML Level * @param version the SBML Version */ public InSpeciesTypeBond(String id, String name, int level, int version) { super(id, name, level, version); if (getLevelAndVersion().compareTo( Integer.valueOf(MultiConstants.MIN_SBML_LEVEL), Integer.valueOf(MultiConstants.MIN_SBML_VERSION)) < 0) { throw new LevelVersionError(getElementName(), level, version); } initDefaults(); }
/** * Creates a MemberConstraint instance with an id, name, level, and version. * * @param id the id * @param name the name * @param level the SBML level * @param version the SBML version */ public MemberConstraint(String id, String name, int level, int version) { super(id, name, level, version); if (getLevelAndVersion().compareTo( Integer.valueOf(GroupsConstants.MIN_SBML_LEVEL), Integer.valueOf(GroupsConstants.MIN_SBML_VERSION)) < 0) { throw new LevelVersionError(getElementName(), level, version); } initDefaults(); }
/** * Creates a SpeciesFeatureType instance with an id, name, level, and version. * * @param id the identifier for this element. * @param name a human-readable name for this element that can be used for display purposes. * @param level the SBML Level * @param version the SBML Version */ public SpeciesFeatureType(String id, String name, int level, int version) { super(id, name, level, version); if (getLevelAndVersion().compareTo( Integer.valueOf(MultiConstants.MIN_SBML_LEVEL), Integer.valueOf(MultiConstants.MIN_SBML_VERSION)) < 0) { throw new LevelVersionError(getElementName(), level, version); } initDefaults(); }
/** * Creates a Submodel instance with an id, name, level, and version. * * @param id the id * @param name the name * @param level the SBML level * @param version the SBML version */ public Submodel(String id, String name, int level, int version) { super(id, name, level, version); if (getLevelAndVersion().compareTo( Integer.valueOf(CompConstants.MIN_SBML_LEVEL), Integer.valueOf(CompConstants.MIN_SBML_VERSION)) < 0) { throw new LevelVersionError(getElementName(), level, version); } initDefaults(); }
/** * Creates a CompartmentReference instance with an id, name, level, and version. * * @param id the identifier for this element. * @param name a human-readable name for this element that can be used for display purposes. * @param level the SBML Level * @param version the SBML Version */ public CompartmentReference(String id, String name, int level, int version) { super(id, name, level, version); if (getLevelAndVersion().compareTo( Integer.valueOf(MultiConstants.MIN_SBML_LEVEL), Integer.valueOf(MultiConstants.MIN_SBML_VERSION)) < 0) { throw new LevelVersionError(getElementName(), level, version); } initDefaults(); }
/** * Creates a Dimension instance with an id, name, level, and version. * * @param id the id * @param name the name * @param level the SBML level * @param version the SBML version */ public Dimension(String id, String name, int level, int version) { super(id, name, level, version); if (getLevelAndVersion().compareTo( Integer.valueOf(ArraysConstants.MIN_SBML_LEVEL), Integer.valueOf(ArraysConstants.MIN_SBML_VERSION)) < 0) { throw new LevelVersionError(getElementName(), level, version); } initDefaults(); }
/** * Creates a SpeciesTypeComponentIndex instance with an id, name, level, and version. * * @param id the identifier for this element. * @param name a human-readable name for this element that can be used for display purposes. * @param level the SBML Level * @param version the SBML Version */ public SpeciesTypeComponentIndex(String id, String name, int level, int version) { super(id, name, level, version); if (getLevelAndVersion().compareTo( Integer.valueOf(MultiConstants.MIN_SBML_LEVEL), Integer.valueOf(MultiConstants.MIN_SBML_VERSION)) < 0) { throw new LevelVersionError(getElementName(), level, version); } initDefaults(); }
@Override public void setVersion(int version) { SBase parent = getParent(); if ((parent != null) && (parent != this) && parent.isSetVersion()) { if (version != parent.getVersion()) { throw new LevelVersionError(parent, this); } } Integer oldVersion = getLevelAndVersion().getV(); lv.setV(version); firePropertyChange(TreeNodeChangeEvent.version, oldVersion, version); }
@Override public void setLevel(int level) { SBase parent = getParent(); if ((parent != null) && (parent != this) && parent.isSetLevel()) { if (level != parent.getLevel()) { throw new LevelVersionError(this, parent); } } Integer oldLevel = getLevelAndVersion().getL(); lv.setL(level); firePropertyChange(TreeNodeChangeEvent.level, oldLevel, lv.getL()); }