Interface Model

All Known Implementing Classes:
ModelImpl

public interface Model
The Model is the container of all DataClasses.

Each DataClass belongs to exact one Model and each Model contains a unique list of DataClasses.

The Model provides several methods (getXSystemClass()) to access the system classes directly. To receive an arbitrary class use the method getClass(String). The name of the system classes can be accessed by the constant CLASS_NAME that is defined in each DataClass, e.g. IntegerClass.CLASS_NAME.

Conceptually, the Model can be interpreted as the namespace of a DataClass. It is possible to have several DataClasses with the same name in the system. But they must belong to different Models.

New DataClasses can be created by using the method DataClass.createSubclass(String). The new data class will be automatically added to the Model. To remove a data class use the method removeClass(String).

Author:
Rainer Maximini
See Also:
  • Field Details

  • Method Details

    • getAggregateSystemClass

      AggregateClass getAggregateSystemClass()
    • getAtomicSystemClass

      AtomicClass getAtomicSystemClass()
    • getBooleanSystemClass

      BooleanClass getBooleanSystemClass()
    • getByteArraySystemClass

      ByteArrayClass getByteArraySystemClass()
    • getChronologicSystemClass

      ChronologicClass getChronologicSystemClass()
    • getClass

      <T extends DataClass> T getClass(String className)
      Searches in the Model for a DataClass with the name className.
      Parameters:
      className - The name of the DataClass
      Returns:
      The DataClass with the given name or null if no data class with the given name exists.
    • getClasses

      List<DataClass> getClasses()
      Returns:
      A list of all DataClasses of the Model. This includes the system as well as the user classes.
    • getDefinedClasses

      Set<String> getDefinedClasses()
      Returns:
      A list of all defined DataClasses of the Model. This includes only classes defined in the Model.
    • getCollectionSystemClass

      CollectionClass getCollectionSystemClass()
    • getDataSystemClass

      DataClass getDataSystemClass()
    • getDateSystemClass

      DateClass getDateSystemClass()
    • getDoubleSystemClass

      DoubleClass getDoubleSystemClass()
    • getIntegerSystemClass

      IntegerClass getIntegerSystemClass()
    • getIntervalSystemClass

      IntervalClass getIntervalSystemClass()
    • getListSystemClass

      ListClass getListSystemClass()
    • getNumericSystemClass

      NumericClass getNumericSystemClass()
    • getURISystemClass

      URIClass getURISystemClass()
    • getRootClass

      DataClassImpl getRootClass()
    • getSetSystemClass

      SetClass getSetSystemClass()
    • getStringSystemClass

      StringClass getStringSystemClass()
    • getTimestampSystemClass

      TimestampClass getTimestampSystemClass()
    • getTimeSystemClass

      TimeClass getTimeSystemClass()
    • getUnionSystemClass

      UnionClass getUnionSystemClass()
    • getVoidSystemClass

      VoidClass getVoidSystemClass()
    • getWorkflowClass

      WorkflowClass getWorkflowClass()
    • getSubWorkflowClass

      SubWorkflowClass getSubWorkflowClass()
    • getDataflowWrapperClass

      DataflowWrapperClass getDataflowWrapperClass()
    • getTaskClass

      TaskClass getTaskClass()
    • getNodeClass

      NodeClass getNodeClass()
    • getSequenceClass

      SequenceClass getSequenceClass()
    • getNESTGraphClass

      NESTGraphClass getNESTGraphClass()
    • getNESTSequentialWorkflowClass

      NESTSequentialWorkflowClass getNESTSequentialWorkflowClass()
    • getNESTWorkflowClass

      NESTWorkflowClass getNESTWorkflowClass()
    • getNESTNodeClass

      NESTNodeClass getNESTNodeClass()
    • getNESTGraphItemClass

      NESTGraphItemClass getNESTGraphItemClass()
    • getNESTControlflowNodeClass

      NESTControlflowNodeClass getNESTControlflowNodeClass()
    • getNESTAndEndNodeClass

      NESTAndEndNodeClass getNESTAndEndNodeClass()
    • getNESTAndStartNodeClass

      NESTAndStartNodeClass getNESTAndStartNodeClass()
    • getNESTLoopStartNodeClass

      NESTLoopStartNodeClass getNESTLoopStartNodeClass()
    • getNESTLoopEndNodeClass

      NESTLoopEndNodeClass getNESTLoopEndNodeClass()
    • getNESTOrEndNodeClass

      NESTOrEndNodeClass getNESTOrEndNodeClass()
    • getNESTOrStartNodeClass

      NESTOrStartNodeClass getNESTOrStartNodeClass()
    • getNESTXorEndNodeClass

      NESTXorEndNodeClass getNESTXorEndNodeClass()
    • getNESTXorStartNodeClass

      NESTXorStartNodeClass getNESTXorStartNodeClass()
    • getNESTTaskNodeClass

      NESTTaskNodeClass getNESTTaskNodeClass()
    • getNESTDataNodeClass

      NESTDataNodeClass getNESTDataNodeClass()
    • getNESTWorkflowNodeClass

      NESTWorkflowNodeClass getNESTWorkflowNodeClass()
    • getNESTSubWorkflowNodeClass

      NESTSubWorkflowNodeClass getNESTSubWorkflowNodeClass()
    • getNESTEdgeClass

      NESTEdgeClass getNESTEdgeClass()
    • getNESTControlflowEdgeClass

      NESTControlflowEdgeClass getNESTControlflowEdgeClass()
    • getNESTConstraintEdgeClass

      NESTConstraintEdgeClass getNESTConstraintEdgeClass()
    • getNESTDataflowEdgeClass

      NESTDataflowEdgeClass getNESTDataflowEdgeClass()
    • getNESTPartOfEdgeClass

      NESTPartOfEdgeClass getNESTPartOfEdgeClass()
    • overwriteMatchingDataClasses

      void overwriteMatchingDataClasses(Model other)
      Another data Model can be provided and all of the containing DataClasses matching the current class hierarchy will be reused in this Model, i.e. references of the DataClasses will be replaced and merged into the hierarchy including subClassLists and superclass references.
      Parameters:
      other -
    • removeClass

      void removeClass(String className) throws IllegalEditException
      Removes a DataClass from the Model. After removing, the DataClass cannot be used any more. Reading is not possible.

      The DataClass can only be removed if no references to this class exists. For example, If the class has sub-classes or is used by an AggregateClass in an attribute an IllegalEditException will be thrown.

      Parameters:
      className - The name of the DataClass that should be removed from the Model.
      Throws:
      IllegalEditException - is thrown if a reference from another class exists
    • addClass

      void addClass(DataClass clazz) throws NameAlreadyExistsException
      Adds a class to the loaded classes. This might be useful if classes need to be added at runtime.
      Parameters:
      clazz - an instance of DataClass that should be added to the list of classes
      Throws:
      NameAlreadyExistsException - if this class name already exists
    • createObject

      <TCakeDataClass extends DataClass, TCakeDataObject extends DataObject> TCakeDataObject createObject(Class<TCakeDataClass> clazz1, Class<TCakeDataObject> clazz2, String className) throws ClassNotFoundException
      Creates the CAKE I - object defined with the given parameters. Strongly typed return.
      Type Parameters:
      TCakeDataClass - The CAKE1-DataClass, which should be used for instantiating the CAKE1-DataObject.
      TCakeDataObject - The CAKE1-DataObject, which should be returned by this method.
      Parameters:
      clazz1 - The CAKE1-DataClass, which should be used for instantiating the CAKE1-DataObject.
      clazz2 - The CAKE1-DataObject, which should be returned by this method.
      className - The name of the CAKE1-class, which should be instantiated. This parameters is redundant to clazz1/clazz2 because they already pindown a specific class/object to instantiate, but due to lack of time we leave it this way.
      Returns:
      The requested class
      Throws:
      ClassNotFoundException
    • createObject

      <T extends DataObject> T createObject(String name)
      Creates the CAKE I - object defined with the given parameters. Weakly typed return (you have to cast for yourself)
      Type Parameters:
      T -
      Parameters:
      name - The internal name of the CAKE-class to instantiate.
      Returns:
      A new instantiated object.
    • addDefinedClassReference

      void addDefinedClassReference(String className)
      Parameters:
      className -