org.eclipse.ohf.stem.core.common
Interface Identifiable

All Superinterfaces:
org.eclipse.emf.ecore.EObject, org.eclipse.emf.common.notify.Notifier, SanityChecker
All Known Subinterfaces:
AggregatingSEIRDiseaseModel, AggregatingSIDiseaseModel, AggregatingSIRDiseaseModel, AreaLabel, CommonBorderRelationshipLabel, Decorator, DeterministicSEIRDiseaseModel, DeterministicSIDiseaseModel, DeterministicSIRDiseaseModel, DiseaseModel, DiseaseModelLabel, DynamicEdgeLabel, DynamicLabel, DynamicNodeLabel, Edge, EdgeDecorator, EdgeLabel, GeographicFeature, Graph, GraphDecorator, Infector, Label, Model, Node, NodeDecorator, NodeLabel, PhysicalRelationshipLabel, PopulationLabel, RealTimeSequencer, Region, RelativePhysicalRelationshipLabel, Scenario, SEIR, SEIRLabel, Sequencer, SequentialSequencer, SI, SIInfector, SILabel, SIR, SIRLabel, StandardDiseaseModel, StandardDiseaseModelLabel, StandardInfector, StandardStochasticDiseaseModel, StaticEdgeLabel, StaticNodeLabel, StochasticDiseaseModel, StochasticSEIRDiseaseModel, StochasticSIDiseaseModel, StochasticSIRDiseaseModel, TestDynamicEdgeLabel, TestDynamicLabel1, TestDynamicNodeLabel, TestEdgeDecorator1, TestGraphDecorator1, TestLabel, TestNodeDecorator1, TestScenarioGraphDecorator1, TestStaticEdgeLabel, TestStaticNodeLabel, TransportRelationshipLabel
All Known Implementing Classes:
AggregatingSEIRDiseaseModelImpl, AggregatingSIDiseaseModelImpl, AggregatingSIRDiseaseModelImpl, AreaLabelImpl, CommonBorderRelationshipLabelImpl, DecoratorImpl, DeterministicSEIRDiseaseModelImpl, DeterministicSIDiseaseModelImpl, DeterministicSIRDiseaseModelImpl, DiseaseModelImpl, DiseaseModelLabelImpl, DynamicEdgeLabelImpl, DynamicLabelImpl, DynamicNodeLabelImpl, EdgeDecoratorImpl, EdgeImpl, EdgeLabelImpl, GeographicFeatureImpl, GraphDecoratorImpl, GraphImpl, IdentifiableImpl, InfectorImpl, LabelImpl, ModelImpl, NodeDecoratorImpl, NodeImpl, NodeLabelImpl, PhysicalRelationshipLabelImpl, PopulationLabelImpl, RealTimeSequencerImpl, RegionImpl, RelativePhysicalRelationshipLabelImpl, ScenarioImpl, SEIRImpl, SEIRLabelImpl, SequencerImpl, SequentialSequencerImpl, SIImpl, SIInfectorImpl, SILabelImpl, SIRImpl, SIRLabelImpl, StandardDiseaseModelImpl, StandardDiseaseModelLabelImpl, StandardInfectorImpl, StandardStochasticDiseaseModelImpl, StaticEdgeLabelImpl, StaticNodeLabelImpl, StochasticDiseaseModelImpl, StochasticSEIRDiseaseModelImpl, StochasticSIDiseaseModelImpl, StochasticSIRDiseaseModelImpl, TestDynamicEdgeLabelImpl, TestDynamicLabel1Impl, TestDynamicNodeLabelImpl, TestEdgeDecorator1Impl, TestGraphDecorator1Impl, TestLabelImpl, TestNodeDecorator1Impl, TestScenarioGraphDecorator1Impl, TestStaticEdgeLabelImpl, TestStaticNodeLabelImpl, TransportRelationshipLabelImpl

public interface Identifiable
extends org.eclipse.emf.ecore.EObject, SanityChecker

An Identifiable instance represents an "identifiable" component in STEM. Such a component is one that is uniquely identified by a URI. An Identifiable also has DublinCore metadata (http://www.dublincore.org/) associated with it that defines its origin and contents.

Virtually all components in a STEM simulation are Identifiable.

See Also:
Graph, Model, Scenario

Method Summary
 DublinCore getDublinCore()
           
 org.eclipse.emf.common.util.URI getTypeURI()
           
 org.eclipse.emf.common.util.URI getURI()
           
 boolean sane()
          This method is for ongoing development and testing purposes.
 void setDublinCore(DublinCore value)
          Sets the value of the 'Dublin Core' containment reference.
 void setTypeURI(org.eclipse.emf.common.util.URI value)
          Sets the value of the 'Type URI' attribute.
 void setURI(org.eclipse.emf.common.util.URI value)
          Sets the value of the 'URI' attribute.
 
Methods inherited from interface org.eclipse.emf.ecore.EObject
eAllContents, eClass, eContainer, eContainingFeature, eContainmentFeature, eContents, eCrossReferences, eGet, eGet, eIsProxy, eIsSet, eResource, eSet, eUnset
 
Methods inherited from interface org.eclipse.emf.common.notify.Notifier
eAdapters, eDeliver, eNotify, eSetDeliver
 

Method Detail

getURI

org.eclipse.emf.common.util.URI getURI()
Returns:
the URL that uniquely identifies this Identifiable component.

setURI

void setURI(org.eclipse.emf.common.util.URI value)
Sets the value of the 'URI' attribute.

Parameters:
value - the new value of the 'URI' attribute.
See Also:
getURI()

getTypeURI

org.eclipse.emf.common.util.URI getTypeURI()
Returns:
the URL that uniquely identifies the type of this Identifiable component.

setTypeURI

void setTypeURI(org.eclipse.emf.common.util.URI value)
Sets the value of the 'Type URI' attribute.

Parameters:
value - the new value of the 'Type URI' attribute.
See Also:
getTypeURI()

getDublinCore

DublinCore getDublinCore()
Returns:
the "Dublin Core" metadata http://www.dublincore.org/ associated with this Identifiable component.

setDublinCore

void setDublinCore(DublinCore value)
Sets the value of the 'Dublin Core' containment reference.

Parameters:
value - the new value of the 'Dublin Core' containment reference.
See Also:
getDublinCore()

sane

boolean sane()
Description copied from interface: SanityChecker
This method is for ongoing development and testing purposes. It performs a "self-check" on the instance of the class. The checking consists of combination of boolean tests and assertions using the Java "assert" facillity. Assertions must be enabled using the "-ea" JVM flag for the assertions to be enabled.

This method is intended to be overridden by extending sub-classes. These classes should first call the method in the super class (i.e., super.sane()) to ensure that the super class is "ok" and then it can issue its own assertions.

 void sane() {
        boolean retValue = super.sane();
 
        // If foo references bar, then bar should reference foo!
        retValue = retValue && (foo.a == bar && bar.a == foo);
        assert(retValue);
 
        return retValue;
 } // sane
 

The idiom retValue = retValue && <boolean test> followed by an assertion of the value of retValue is a typical pattern. If followed, then once a problem is detected, an assertion will be thrown, or the rest of the tests will be skipped and the value of false returned. By having sane return a value rather than simply relying upon the assert keyword sanity testing can occur even if assertions are not enabled.

The sane method should be called when the instance is known to be "stable" so the consistency checks should complete with no problems (if all is well).

Specified by:
sane in interface SanityChecker
Returns:
true if the instance is "sane", false otherwise.