Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## edu.udo.cs.miningmart.m4
Interface Case

All Superinterfaces:
  M4Data, M4Object

All Known Implementing Classes:
  Case

    public interface Case

extends M4Data

Version:
  $Id: Case.java,v 1.9 2006/09/27 14:59:58 euler Exp $
Author:
  Timm Euler, Daniel Hakenjos

Field Summary
`static java.lang.String` | `DESIGN_MODE` Constant that can be used to set the Case Mode to DESIGN
`static java.lang.String` | `FINAL_MODE` Constant that can be used to set the Case Mode to FINAL
`static java.lang.String` | `TEST_MODE` Constant that can be used to set the Case Mode to TEST

Method Summary
`void` | `addChain(Chain chain)` Adds a new Chain to this case.
`void` | `addConcept(Concept con)` Adds a new Concept to this case.
`void` | `addStep(Step step)` Adds a `Step` to this `Case`.
`void` | `addStepDependency(Step before, Step after)` This method adds dependencies between `Step`s and brings the `Step`s in a sequential order again, if necessary and if they have been in sequential order before adding the dependency.
`void` | `arrangeConceptsOnGrid(int gridLength)` Rounds all coordinates of concepts of this case so that their new value modulo the given gridLength is 0.
`void` | `arrangeStepsOnGrid(int gridLength)` Rounds all coordinates of steps of this case so that their new value modulo the given gridLength is 0.
`boolean` | `containsDependency(Step before, Step after)` Checks for a direct (explicitly added) dependency between the two `Step`s.
`Case` | `copy()`
`Chain` | `createChain(java.lang.String name)` Creates an empty Chain belonging to this Case.
`Chain` | `createChain(java.lang.String name, java.util.Collection stepsAndChains)` Creates a Chain that subsumes the given steps and chains.
`Concept` | `createConcept(java.lang.String name, java.lang.String type)` Creates an empty Concept belonging to this Case.
`Concept` | `createConceptAndRelationsFromTables(java.lang.String tableName)` This method creates a Columnset and Concept for the given table/view name, and also creates a Columnset and Concept for EVERY table that is referenced from the first one by a foreign key reference, and also creates an M4 Relation for those references.
`Concept` | `createConceptFromColumnset(Columnset cs)` Creates a Concept that belongs to this Case and is connected to the given Columnset.
`Concept` | `createConceptFromTable(java.lang.String tableName)` Creates a Concept that belongs to this Case and that directly models a database table or view with the given name.
`Relation` | `createManyToManyRelation(java.lang.String relName, java.util.Collection fromConceptKeyAttribs, java.util.Collection toConceptKeyAttribs, java.lang.String crossTableName, java.util.Collection crossLinkToFromConceptNames, java.util.Collection crossLinkToToConceptNames)` Creates a many-to-many relation.
`java.util.Collection` | `createManyToManyRelationsFromCrossTable(java.lang.String crossTableName, java.util.Collection<java.lang.String> allowedDbObjects)` Creates many-to-many relations with the given table name as cross table.
`Relation` | `createOneToManyRelation(java.lang.String relName, java.util.Collection fromConceptKeyAttribs, java.util.Collection toConceptKeyAttribs)` Creates a one-to-many relation.
`Step` | `createStep(java.lang.String name)` Creates an empty Step belonging to this Case.
`Step` | `findCandidateStepForMaterialisation()` This method goes through all steps of this case and tries to find a step whose output concept deserves materialisation.
`DataModelConnection` | `findEntryPoint(java.util.Collection<Concept> targetDataModel, MmSchemaMatcher theMatcher)` Returns the best connection from any initial or intermediate data model of this case to the given target data model.
`DataModelConnection` | `findMatchingForInputDataModel(java.util.Collection<Concept> targetDataModel, MmSchemaMatcher theMatcher)` Tries to match the initial concepts of this case (of type DB) to the concepts given as targetDataModel.
`DataModelConnection` | `findMatchingForResultingDataModel(Step theStep, java.util.Collection<Concept> targetDataModel, MmSchemaMatcher theMatcher)` Tries to match the resulting data view of the given step to the concepts given as targetDataModel.
`java.util.Collection` | `getAllChains()` Active getter of the Chains of this Case.
`java.util.Collection` | `getAllConceptNames()` Gets the names of all concepts.
`java.util.Collection` | `getAllRelations()` Returns all Relations that this Case has.
`java.util.Collection` | `getAllStepNames()` Returns a Collection with all Step names in the current Case.
`Chain` | `getChainByName(java.lang.String name)` Retrieve a Chain by its name.
`Concept` | `getConcept(java.lang.String conceptName)`
`java.util.Collection` | `getConcepts()` Active getter of the Concepts of this Case.
`java.util.Collection` | `getDependentStepsFor(Step step)` Gets a `Collection` of the stepIds that are dependent on the given step, ie must be compiled after the given step.
`java.util.Collection` | `getDirectlyDependentSteps(Step step)` Gets a `Collection` of the steps that are directly dependent on the given step.
`java.util.Collection` | `getFinalSteps()` Returns all steps of this case that do not have a successor.
`java.util.Collection` | `getInputDataModel()` Returns a collection of all concepts of type DB in this Case.
`java.lang.String` | `getNewNameOfChangedFeature(java.lang.String oldName)` Returns the new name of the feature with the given old name, if that new name was stored previously using storeChangedNameOfFeature(String,String).
`int` | `getNumberOfSteps()`
`java.lang.String` | `getOldNameOfChangedFeature(java.lang.String newName)` Returns the old name of the feature with the given new name, if that old name was stored previously using storeChangedNameOfFeature(String,String).
`java.util.Map` | `getOperatorToStepMap()` Returns a map that maps operators that occur in this case to a collection of the steps in which they occur.
`Step` | `getPredecessorIdOf(Step step)` Gets the predecessor step, given the calculated sequential order.
`Relation` | `getRelation(java.lang.String relationName)` Returns the relation with the given name if any exists; otherwise NULL is returned.
`java.util.Iterator` | `getReverseIterator()`
`Step` | `getStepByName(java.lang.String name)` This method finds a `Step` related to this `Case` by the `Step`'s M4 name
`Step` | `getStepIdNo(int i)` Gets the step i in sequential order.
`java.util.Iterator` | `getStepIterator()`
`java.util.Collection` | `getStepsToCompileBefore(Step step, boolean ignoreCompiledStatusOfSteps)` This method returns a Collection of all Steps on which the given Step is dependent.
`Step` | `getSuccessorOf(Step step)` Gets the successor step, given the calculated sequential order.
`java.lang.String` | `getTheMode()` Get the Case mode.
`java.util.Vector` | `getTheSteps()` Active getter
`java.util.Collection` | `getTopLevelChains()` Active getter of the Chains of this Case.
`int` | `indexOfStep(Step step)`
`void` | `insertMaterialisationAfterStep(Step precedingStep, Step materialisingStep)` This method adjusts the parameters of the given steps because the second one was inserted after the first one
`void` | `putConceptsOnGrid()` This method arranges the concepts of this case on a grid without using their previous positions.
`void` | `removeAllSteps()` All Steps of a Case will be removed including their Parameters.
`boolean` | `removeChain(Chain chain)` Removes a Chain from this case.
`void` | `removeChain(java.lang.String name)` Remove a Chain by its name.
`boolean` | `removeConcept(Concept con)` Removes a Concept from this case.
`boolean` | `removeStep(Step step)` Removes a `Step` and all of its dependencies from this `Case`.
`void` | `removeStep(java.lang.String name)` The specified Step will be removed including its Parameters.
`boolean` | `removeStepDependency(Step before, Step after)` A dependency (or edge in graph terminology) between the two `Step`s is removed.
`void` | `resolveChain(Chain toBeResolved)` The given chain will be resolved if it is a top level chain and if it does not have any Steps, only subchains.
`void` | `setTheMode(java.lang.String newMode)` Set the Case mode.
`java.util.Collection` | `sortSteps(java.util.Collection someSteps)` Sorts a collection of steps according to the global step order given by the step transitions/dependencies.
`void` | `store()` Write all M4 data pertaining to this case through to the database.
`void` | `storeChangedNameOfFeature(java.lang.String oldName, java.lang.String newName)` Serves to remember a changed feature name globally.

Methods inherited from interface edu.udo.cs.miningmart.m4.M4Data
`deleteSoon, getDocumentation, getValidName, isDirty, isWaitingForDelete, setDocumentation`

Methods inherited from interface edu.udo.cs.miningmart.m4.M4Object
`doPrint, doPrint, equals, executeBusinessSingleValueSqlRead, executeBusinessSingleValueSqlReadL, executeBusinessSqlRead, executeBusinessSqlWrite, executeM4SingleValueSqlRead, executeM4SingleValueSqlReadL, executeM4SqlRead, executeM4SqlWrite, getCasePrintObject, getId, getM4Db, getM4ObjectFromCache, getName, getNextM4SequenceValue, isNew, load, print, putM4ObjectToCache, replaceSpacesInName, setId, setName, setNotNew`

Field Detail

### TEST_MODE

    static final java.lang.String TEST_MODE

  Constant that can be used to set the Case Mode to TEST

  See Also:
    Constant Field Values

### DESIGN_MODE

    static final java.lang.String DESIGN_MODE

  Constant that can be used to set the Case Mode to DESIGN

  See Also:
    Constant Field Values

### FINAL_MODE

    static final java.lang.String FINAL_MODE

  Constant that can be used to set the Case Mode to FINAL

  See Also:
    Constant Field Values

Method Detail

### addStepDependency

    void addStepDependency(Step before,
                           Step after)
                           throws M4Exception

  This method adds dependencies between `Step`s and brings the `Step`s in a sequential order again, if necessary and if they have been in sequential order before adding the dependency.

  Parameters:
    `before` - a `Step` part of this `Case`
    `after` - a `Step` part of this `Case` and depending on `Step` `before`.
  Throws:
    `M4Exception`

### containsDependency

    boolean containsDependency(Step before,
                               Step after)
                               throws M4Exception

  Checks for a direct (explicitly added) dependency between the two `Step`s.

  Parameters:
    `stepBefore` - a `Step` part of this `Case`
    `stepAfter` - another `Step` part of this `Case`
  Returns:
    `true` if the second `Step` directly depends on the first one. If one of the `Step`s is not part of the `Case` then `false` is returned.
  Throws:
    `M4Exception`

### removeStepDependency

    boolean removeStepDependency(Step before,
                                 Step after)
                                 throws M4Exception

  A dependency (or edge in graph terminology) between the two `Step`s is removed.

  Parameters:
    `before` - a `Step` part of this `Case`
    `after` - a `Step` part of this `Case`, and depending on `Step` `before`
  Returns:
    `true` iff the dependency was found and could be removed
  Throws:
    `M4Exception`

### setTheMode

    void setTheMode(java.lang.String newMode)
                    throws M4Exception

  Set the Case mode. Allowed constants are given by the public static variables TESTMODE and FINALMODE of this class.

  Parameters:
    `newMode` - The new case mode. Use the public static variables TESTMODE and FINALMODE of this class.
  Throws:
    `M4Exception`

### getTheMode

    java.lang.String getTheMode()

  Get the Case mode.

  Returns:
    A String with the value of one of the public static fields TESTMODE and FINALMODE of this class.

### findMatchingForInputDataModel

    DataModelConnection findMatchingForInputDataModel(java.util.Collection<Concept> targetDataModel,
                                                      MmSchemaMatcher theMatcher)
                                                      throws SchemaMatchException,
                                                             M4Exception

  Tries to match the initial concepts of this case (of type DB) to the concepts given as targetDataModel. Returns all matchings found.

  Parameters:
    `targetDataModel` -
    `theMatcher` -
  Returns:
  Throws:
    `SchemaMatchException`
    `M4Exception`

### findEntryPoint

    DataModelConnection findEntryPoint(java.util.Collection<Concept> targetDataModel,
                                       MmSchemaMatcher theMatcher)
                                       throws SchemaMatchException,
                                              M4Exception

  Returns the best connection from any initial or intermediate data model of this case to the given target data model.

  Parameters:
    `targetDataModel` -
    `theMatcher` -
  Returns:
  Throws:
    `SchemaMatchException`
    `M4Exception`

### findMatchingForResultingDataModel

    DataModelConnection findMatchingForResultingDataModel(Step theStep,
                                                          java.util.Collection<Concept> targetDataModel,
                                                          MmSchemaMatcher theMatcher)
                                                          throws SchemaMatchException,
                                                                 M4Exception

  Tries to match the resulting data view of the given step to the concepts given as targetDataModel. Returns all matchings found.

  Parameters:
    `theStep` - the given step
    `targetDataModel` -
    `theMatcher` -
  Returns:
  Throws:
    `SchemaMatchException`
    `M4Exception`

### getStepIdNo

    Step getStepIdNo(int i)
                     throws M4Exception

  Gets the step i in sequential order.

  Returns:
    Returns a step
  Throws:
    `M4Exception`

### getNumberOfSteps

    int getNumberOfSteps()
                         throws M4Exception

  Returns:
    the number of steps of this case.
  Throws:
    `M4Exception`

### getPredecessorIdOf

    Step getPredecessorIdOf(Step step)
                            throws M4Exception

  Gets the predecessor step, given the calculated sequential order.

  Parameters:
    `step` - The step for which the predecessor is wanted.
  Returns:
    the predecessor step
  Throws:
    `M4Exception`

### getSuccessorOf

    Step getSuccessorOf(Step step)
                        throws M4Exception

  Gets the successor step, given the calculated sequential order.

  Parameters:
    `step` - The step for which the successor is wanted.
  Returns:
    the successor step
  Throws:
    `M4Exception`

### indexOfStep

    int indexOfStep(Step step)
                    throws M4Exception

  Returns:
    the index of the Step with the given Id, if part of this case. The result depends of the chosen (but fixed) sequential order of the `Sequentializer`!
  Throws:
    `M4Exception`

### getStepIterator

    java.util.Iterator getStepIterator()
                                       throws M4Exception

  Returns:
    an Iterator providing the Steps of this Case. The order depends on the `Sequentializer`.
  Throws:
    `M4Exception`

### getReverseIterator

    java.util.Iterator getReverseIterator()
                                          throws M4Exception

  Returns:
    an Iterator providing the Steps in reverse order. The order depends on the `Sequentializer`!
  Throws:
    `M4Exception`

### getDependentStepsFor

    java.util.Collection getDependentStepsFor(Step step)
                                              throws M4Exception

  Gets a `Collection` of the stepIds that are dependent on the given step, ie must be compiled after the given step.

  Parameters:
    `startStepId` - The step for which the dependent steps are wanted.
  Returns:
    The dependent steps as a Collection.
  Throws:
    `M4Exception`

### getStepsToCompileBefore

    java.util.Collection getStepsToCompileBefore(Step step,
                                                 boolean ignoreCompiledStatusOfSteps)
                                                 throws M4Exception

  This method returns a Collection of all Steps on which the given Step is dependent. That means, all Steps are returned that must be compiled before the given Step can be compiled. By the parameter ignoreCompiledStatusOfSteps, one can specify whether the method considers only the graph structure of M4 Step dependencies, and ignores whether some of the Steps to be returned have already been compiled (and thus would not have to be compiled again) - or whether this compilation status of Steps should be taken into account. In the latter case, the search for predecessors of the given Steps ends, on every path that leads to the given Step, at the last Step that is already compiled.

  Parameters:
    `step` - the Step whose preceding graph is returned
    `ignoreCompiledStatusOfSteps` - if TRUE, *all* Steps that lead to the given Step are returned; if FALSE, only those starting at the last compiled Step on each path that leads to the given Step are returned.
  Returns:
    a Collection of all Steps that must, in principle, be compiled before the given Step can be compiled
  Throws:
    `M4Exception`

### getDirectlyDependentSteps

    java.util.Collection getDirectlyDependentSteps(Step step)
                                                   throws M4Exception

  Gets a `Collection` of the steps that are directly dependent on the given step. This is useful for the HCI to just visualize the explicitly stored dependencies.

  Parameters:
    `step` - The step for which the dependent steps are wanted.
  Returns:
    The dependent steps as a Collection or `null`, if the specified `Step` is not found.
  Throws:
    `M4Exception`

### sortSteps

    java.util.Collection sortSteps(java.util.Collection someSteps)
                                   throws M4Exception

  Sorts a collection of steps according to the global step order given by the step transitions/dependencies.

  Parameters:
    `someSteps` - The collection of steps to be sorted
  Returns:
    A sorted collection of steps
  Throws:
    `M4Exception`

### storeChangedNameOfFeature

    void storeChangedNameOfFeature(java.lang.String oldName,
                                   java.lang.String newName)

  Serves to remember a changed feature name globally.

  Parameters:
    `oldName` -
    `newName` -

### getNewNameOfChangedFeature

    java.lang.String getNewNameOfChangedFeature(java.lang.String oldName)

  Returns the new name of the feature with the given old name, if that new name was stored previously using storeChangedNameOfFeature(String,String).

  Parameters:
    `oldName` - the old name
  Returns:
    a new name or null

### getOldNameOfChangedFeature

    java.lang.String getOldNameOfChangedFeature(java.lang.String newName)

  Returns the old name of the feature with the given new name, if that old name was stored previously using storeChangedNameOfFeature(String,String).

  Parameters:
    `newName` - the new name
  Returns:
    an old name or null

### getAllConceptNames

    java.util.Collection getAllConceptNames()
                                            throws M4Exception

  Gets the names of all concepts.

  Returns:
    The names (String).
  Throws:
    `M4Exception`

### getConcepts

    java.util.Collection getConcepts()
                                     throws M4Exception

  Active getter of the Concepts of this Case.

  Returns:
    a `Collection` of `Concept`s
  Throws:
    `M4Exception`

### getInputDataModel

    java.util.Collection getInputDataModel()
                                           throws M4Exception

  Returns a collection of all concepts of type DB in this Case.

  Returns:
    a `Collection` of `Concept`s
  Throws:
    `M4Exception`

### addConcept

    void addConcept(Concept con)
                    throws M4Exception

  Adds a new Concept to this case.

  Parameters:
    `con` - the new `Concept`
  Throws:
    `M4Exception`

### removeConcept

    boolean removeConcept(Concept con)
                          throws M4Exception

  Removes a Concept from this case.

  Parameters:
    `con` - the `Concept` to be removed
  Returns:
    `true` if `Concept` was found and could be removed
  Throws:
    `M4Exception`

### getAllChains

    java.util.Collection getAllChains()
                                      throws M4Exception

  Active getter of the Chains of this Case. Attention: It returns ALL chains of this Case, including subchains of subchains etc.! Compare to method `getTopLevelChains`.

  Returns:
    a `Collection` of `Chain`s
  Throws:
    `M4Exception`

### getTopLevelChains

    java.util.Collection getTopLevelChains()
                                           throws M4Exception

  Active getter of the Chains of this Case. Attention: It returns ONLY the top-level chains of this Case, that is, the Chains that do not have a parent chain. Compare to method `getAllChains`.

  Returns:
    a `Collection` of `Chain`s
  Throws:
    `M4Exception`

### getChainByName

    Chain getChainByName(java.lang.String name)
                         throws M4Exception

  Retrieve a Chain by its name.

  Parameters:
    `name` - the Name
  Throws:
    `M4Exception`

### removeChain

    void removeChain(java.lang.String name)
                     throws M4Exception

  Remove a Chain by its name.

  Parameters:
    `name` - the Name
  Throws:
    `M4Exception`

### addChain

    void addChain(Chain chain)
                  throws M4Exception

  Adds a new Chain to this case. It does not have to be a top level chain (ie a chain without a parent chain).

  Parameters:
    `chain` - the new `Chain`
  Throws:
    `M4Exception`

### removeChain

    boolean removeChain(Chain chain)
                        throws M4Exception

  Removes a Chain from this case.

  Parameters:
    `chain` - the `Chain` to be removed
  Returns:
    `true` if `Chain` was found and could be removed
  Throws:
    `M4Exception`

### getStepByName

    Step getStepByName(java.lang.String name)
                       throws M4Exception

  This method finds a `Step` related to this `Case` by the `Step`'s M4 name

  Parameters:
    `name` - the name of the `Step` object
  Returns:
    the `Step` or `null`
  Throws:
    `M4Exception`

### getTheSteps

    java.util.Vector getTheSteps()
                                 throws M4Exception

  Active getter

  Returns:
    a `Collection` of all `Step`s of this `Case`
  Throws:
    `M4Exception`

### addStep

    void addStep(Step step)
                 throws M4Exception

  Adds a `Step` to this `Case`.

  Parameters:
    `step` - the `Step` to be added
  Throws:
    `M4Exception`

### removeStep

    boolean removeStep(Step step)
                       throws M4Exception

  Removes a `Step` and all of its dependencies from this `Case`.

  Parameters:
    `step` - the `Step` to be added
  Throws:
    `M4Exception`

### copy

    Case copy()
              throws M4Exception

  Throws:
    `M4Exception`

### createStep

    Step createStep(java.lang.String name)
                    throws M4Exception

  Creates an empty Step belonging to this Case. The name of the Step should be unique within the Case.

  Throws:
    `CreateException` - when an error occurs during creation of the object.
    `NameExistsException` - when the provided name already exists.
    `M4Exception`

### getAllStepNames

    java.util.Collection getAllStepNames()
                                         throws M4Exception

  Returns a Collection with all Step names in the current Case.

  Throws:
    `M4Exception`

### removeStep

    void removeStep(java.lang.String name)
                    throws M4Exception

  The specified Step will be removed including its Parameters. Concepts and BaseAttributes of types BASE and DB however will not be removed.

  Throws:
    `M4Exception`

### removeAllSteps

    void removeAllSteps()
                        throws M4Exception

  All Steps of a Case will be removed including their Parameters. Concepts and BaseAttributes of types BASE and DB however will not be removed.

  Throws:
    `M4Exception`

### findCandidateStepForMaterialisation

    Step findCandidateStepForMaterialisation()
                                             throws M4Exception

  This method goes through all steps of this case and tries to find a step whose output concept deserves materialisation. The method can be called several times and will return different steps as long as candidates exist. If NULL is returned, all further calls will also return NULL unless the case is changed.

  Throws:
    `M4Exception`

### insertMaterialisationAfterStep

    void insertMaterialisationAfterStep(Step precedingStep,
                                        Step materialisingStep)
                                        throws M4Exception

  This method adjusts the parameters of the given steps because the second one was inserted after the first one

  Parameters:
    `precedingStep` - the step after which the other one was inserted
    `materialisingStep` - the step that was inserted after the other step
  Throws:
    `M4Exception`

### getFinalSteps

    java.util.Collection getFinalSteps()
                                       throws M4Exception

  Returns all steps of this case that do not have a successor.

  Throws:
    `M4Exception`

### arrangeStepsOnGrid

    void arrangeStepsOnGrid(int gridLength)
                            throws M4Exception

  Rounds all coordinates of steps of this case so that their new value modulo the given gridLength is 0.

  Parameters:
    `gridLength` - the length of a grid edge of the grid on which the steps are to be rearranged
  Throws:
    `M4Exception`

### arrangeConceptsOnGrid

    void arrangeConceptsOnGrid(int gridLength)
                               throws M4Exception

  Rounds all coordinates of concepts of this case so that their new value modulo the given gridLength is 0.

  Parameters:
    `gridLength` - the length of a grid edge of the grid on which the concepts are to be rearranged
  Throws:
    `M4Exception`

### putConceptsOnGrid

    void putConceptsOnGrid()
                           throws M4Exception

  This method arranges the concepts of this case on a grid without using their previous positions. They are simply put on a graphical matrix. The links between the concepts are not used either. The resulting arrangement may be inconvenient.

  Throws:
    `M4Exception`

### createChain

    Chain createChain(java.lang.String name)
                      throws M4Exception

  Creates an empty Chain belonging to this Case. The name of the Chain should be unique within the Case.

  Parameters:
    `name` - the name to be given to the new chain
  Returns:
    the created chain
  Throws:
    `M4Exception`

### createChain

    Chain createChain(java.lang.String name,
                      java.util.Collection stepsAndChains)
                      throws M4Exception

  Creates a Chain that subsumes the given steps and chains. It will not be given any parent chain, so it will be a top level chain in this Case.

  Parameters:
    `name` - the name to be given to the new chain
    `stepsAndChains` - a `Collection` of `Step`s and/or `Chain`s.
  Returns:
    the created chain
  Throws:
    `M4Exception`

### resolveChain

    void resolveChain(Chain toBeResolved)
                      throws M4Exception

  The given chain will be resolved if it is a top level chain and if it does not have any Steps, only subchains. Otherwise an M4Exception is thrown. The subchains of the given chain will be new top-level chains of this Case.

  Throws:
    `M4Exception`

### createConcept

    Concept createConcept(java.lang.String name,
                          java.lang.String type)
                          throws M4Exception

  Creates an empty Concept belonging to this Case. The name of the Concept must be unique within the Case.

  Parameters:
    `name` - the name for the concept to be created
    `type` - the type of the concept (see Concept.TYPE_...)
  Throws:
    `M4Exception`

### createConceptFromTable

    Concept createConceptFromTable(java.lang.String tableName)
                                   throws M4Exception

  Creates a Concept that belongs to this Case and that directly models a database table or view with the given name. The concept will have exactly the given name. For each column of the table/view a BaseAttribute is created and attached to the Concept. The given name must be a valid name of a database table or view in the current business data schema, otherwise an exception is thrown.

  Parameters:
    `tableName` - the name of a table or view in the business schema
  Throws:
    `M4Exception`

### createConceptFromColumnset

    Concept createConceptFromColumnset(Columnset cs)
                                       throws M4Exception

  Creates a Concept that belongs to this Case and is connected to the given Columnset. The concept directly reflects the Columnset, that is, its name and the names of the BaseAttributes are taken from the Columnset and its Columns.

  Parameters:
    `cs` - the given Columnset
  Returns:
    the new Concept
  Throws:
    `M4Exception`

### createOneToManyRelation

    Relation createOneToManyRelation(java.lang.String relName,
                                     java.util.Collection fromConceptKeyAttribs,
                                     java.util.Collection toConceptKeyAttribs)
                                     throws M4Exception

  Creates a one-to-many relation. The name must be valid for this Case. There must be equally many Features in the from/to key attribute collections.

  Parameters:
    `relName` - a valid name for a new Relation in this Case
    `fromConceptKeyAttribs` - a Collection of the Features that make up the key attributes in the FromConcept
    `toConceptKeyAttribs` - a Collection of the Features that make up the key attributes in the ToConcept
  Returns:
    the newly created Relation
  Throws:
    `M4Exception`

### createManyToManyRelation

    Relation createManyToManyRelation(java.lang.String relName,
                                      java.util.Collection fromConceptKeyAttribs,
                                      java.util.Collection toConceptKeyAttribs,
                                      java.lang.String crossTableName,
                                      java.util.Collection crossLinkToFromConceptNames,
                                      java.util.Collection crossLinkToToConceptNames)
                                      throws M4Exception

  Creates a many-to-many relation. The name must be valid for this Case. There must be equally many Features in the from/to key attribute collections as there are names in the from/to cross link name collections.

  Parameters:
    `relName` - a valid name for a new Relation in this Case
    `fromConceptKeyAttribs` - a Collection of the Features that make up the key attributes in the FromConcept
    `toConceptKeyAttribs` - a Collection of the Features that make up the key attributes in the ToConcept
    `crossTableName` - the name of the table in the business data schema that serves as the cross table
    `crossLinkToFromConceptNames` - a Collection with the names of the cross table columns that provide the foreign key to the primary key of the FromConcept
    `crossLinkToToConceptNames` - a Collection with the names of the cross table columns that provide the foreign key to the primary key of the ToConcept
  Returns:
    the newly created Relation
  Throws:
    `M4Exception`

### createManyToManyRelationsFromCrossTable

    java.util.Collection createManyToManyRelationsFromCrossTable(java.lang.String crossTableName,
                                                                 java.util.Collection<java.lang.String> allowedDbObjects)
                                                                 throws M4Exception

  Creates many-to-many relations with the given table name as cross table. This only works if the foreign key information is stored in the database. If the given collection of table names is not null, only such relations are created that connect tables from that collection.

  Parameters:
    `crossTableName` -
  Returns:
  Throws:
    `M4Exception`

### createConceptAndRelationsFromTables

    Concept createConceptAndRelationsFromTables(java.lang.String tableName)
                                                throws M4Exception

  This method creates a Columnset and Concept for the given table/view name, and also creates a Columnset and Concept for EVERY table that is referenced from the first one by a foreign key reference, and also creates an M4 Relation for those references. Concepts and Columnsets for the other tables/views are only created if no such object with the same name exists yet in the M4 cache. At the moment only one-to-many relations are created!

  Parameters:
    `tableName` - the given table name
  Returns:
    the first Concept, from which the referenced Concepts can be found by following the M4 Relations.
  Throws:
    `M4Exception`

### getConcept

    Concept getConcept(java.lang.String conceptName)
                       throws M4Exception

  Throws:
    `M4Exception`

### store

    void store()
               throws M4Exception

  Write all M4 data pertaining to this case through to the database.

  Throws:
    `M4Exception`

### getAllRelations

    java.util.Collection getAllRelations()
                                         throws M4Exception

  Returns all Relations that this Case has.

  Returns:
    a Collection of Relations
  Throws:
    `M4Exception`

### getRelation

    Relation getRelation(java.lang.String relationName)
                         throws M4Exception

  Returns the relation with the given name if any exists; otherwise NULL is returned.

  Parameters:
    `relationName` -
  Returns:
  Throws:
    `M4Exception`

### getOperatorToStepMap

    java.util.Map getOperatorToStepMap()
                                       throws M4Exception

  Returns a map that maps operators that occur in this case to a collection of the steps in which they occur.

  Returns:
    a map from operators to collections of steps
  Throws:
    `M4Exception`

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2001-2005