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 Relation

All Superinterfaces:
  GraphicalM4Object, M4Data, M4Object, ParameterObject

All Known Implementing Classes:
  Relation

    public interface Relation

extends ParameterObject

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

Method Summary
`void` | `addSubRelationship(Relation relationship)`
`void` | `changeAllKeys(java.util.Collection fromConceptAttribs, java.util.Collection toConceptAttribs, java.util.Collection crossToFromKeyNames, java.util.Collection crossToToKeyNames)` Adapt the keys of this relation.
`void` | `changeCrossTable(java.lang.String newCrossTableName)` Change the cross table of this relation.
`void` | `changeFromAndToKeys(java.util.Collection fromConceptAttribs, java.util.Collection toConceptAttribs)` Adapt the keys of this relation.
`Relation` | `copy(Concept fromConcept, Concept toConcept)`
`Columnset` | `createCrossLinkColumnset(java.lang.String name, java.lang.String schema, java.lang.String type)` Creates a ColumnSet that will be connected to this Relation.
`java.util.Collection` | `getAllSubRelationships()`
`Columnset` | `getCrossLinkColumnSet()`
`ForeignKey` | `getFromKey()` Getter method.
`Columnset` | `getResultOfJoin()` This method creates a Columnset that represents the inner join resulting from joining the FromConcept and the ToConcept.
`java.util.Collection` | `getStepsWhereThisIsInputRelation()` Returns all Steps in the Case that use this Relation as an input.
`Relation` | `getSubRelation(java.lang.String name)`
`java.util.Collection` | `getSubRelations()`
`Relation` | `getSuperRelation()`
`Concept` | `getTheFromConcept()` Getter method.
`Concept` | `getTheToConcept()` Getter method.
`ForeignKey` | `getToKey()` Getter method.
`boolean` | `isManyToManyRelation()` Returns true iff this Relation models an n:m relationship.
`boolean` | `isOneToManyRelation()` Returns true iff this Relation models a 1:n relationship.
`boolean` | `isRelationallyValid()` This method returns information about the relational validity of the object.
`void` | `removeAllSubRelationships()`
`void` | `removeCrossLinkColumnset()` Removes the ColumnSet for this Relation.
`void` | `removeFromKey()`
`void` | `removeSubRelationship(java.lang.String name)`
`void` | `removeSuperRelation()` Remove the link to the superRelationship.
`void` | `removeToKey()`
`void` | `setCrossLinkColumnSet(Columnset cs)` Setter method.
`void` | `setFromKey(ForeignKey newFromKey)` Setter method.
`void` | `setM2mKeys(ForeignKey fromFK, ForeignKey toFK)` Sets the key fields that define a many-to-many relationship on the relational level for this Relationship.
`void` | `setSuperRelation(Relation superRelationship)`
`void` | `setTheFromConcept(Concept c)` Setter method.
`void` | `setTheToConcept(Concept c)` Setter method.
`void` | `setToKey(ForeignKey newToKey)` Setter method.

Methods inherited from interface edu.udo.cs.miningmart.m4.ParameterObject
`addParameterReference, getParameterReferences, removeParameterReference`

Methods inherited from interface edu.udo.cs.miningmart.m4.GraphicalM4Object
`getPoint, setPoint`

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`

Method Detail

### setTheToConcept

    void setTheToConcept(Concept c)
                         throws M4Exception

  Setter method.

  Parameters:
    `c` - the new value
  Throws:
    `M4Exception`

### getTheToConcept

    Concept getTheToConcept()
                            throws M4Exception

  Getter method.

  Returns:
    the value
  Throws:
    `M4Exception`

### setTheFromConcept

    void setTheFromConcept(Concept c)
                           throws M4Exception

  Setter method.

  Parameters:
    `c` - the new value
  Throws:
    `M4Exception`

### getTheFromConcept

    Concept getTheFromConcept()
                              throws M4Exception

  Getter method.

  Returns:
    the value
  Throws:
    `M4Exception`

### getResultOfJoin

    Columnset getResultOfJoin()
                              throws M4Exception

  This method creates a Columnset that represents the inner join resulting from joining the FromConcept and the ToConcept. The M4 Columns are also created. However, the view corresponding to the new Columnset is not created in the database.

  Returns:
    a Columnset
  Throws:
    `M4Exception`

### getStepsWhereThisIsInputRelation

    java.util.Collection getStepsWhereThisIsInputRelation()
                                                          throws M4Exception

  Returns all Steps in the Case that use this Relation as an input.

  Returns:
    a Collection of Steps
  Throws:
    `M4Exception`

### setToKey

    void setToKey(ForeignKey newToKey)
                  throws M4Exception

  Setter method.

  Parameters:
    `newToKey` - the new toKey
  Throws:
    `M4Exception`

### getToKey

    ForeignKey getToKey()
                        throws M4Exception

  Getter method.

  Returns:
    the value
  Throws:
    `M4Exception`

### removeToKey

    void removeToKey()
                     throws M4Exception

  Throws:
    `M4Exception`

### setFromKey

    void setFromKey(ForeignKey newFromKey)
                    throws M4Exception

  Setter method.

  Parameters:
    `newFromKey` - the new FromKey
  Throws:
    `M4Exception`

### getFromKey

    ForeignKey getFromKey()
                          throws M4Exception

  Getter method.

  Returns:
    the value
  Throws:
    `M4Exception`

### removeFromKey

    void removeFromKey()
                       throws M4Exception

  Throws:
    `M4Exception`

### getCrossLinkColumnSet

    Columnset getCrossLinkColumnSet()
                                    throws M4Exception

  Returns:
    The Columnset that realizes this relation if it is an n:m relation. For 1:n relations, null is returned.
  Throws:
    `M4Exception`

### setCrossLinkColumnSet

    void setCrossLinkColumnSet(Columnset cs)
                               throws M4Exception

  Setter method.

  Parameters:
    `cs` - The new cross columnset for the n:m relation.
  Throws:
    `M4Exception`

### changeCrossTable

    void changeCrossTable(java.lang.String newCrossTableName)
                          throws M4Exception

  Change the cross table of this relation. If there is no columnset yet that represents the table with the given name, such a columnset is created.

  Parameters:
    `newCrossTableName` -
  Throws:
    `M4Exception`

### changeAllKeys

    void changeAllKeys(java.util.Collection fromConceptAttribs,
                       java.util.Collection toConceptAttribs,
                       java.util.Collection crossToFromKeyNames,
                       java.util.Collection crossToToKeyNames)
                       throws M4Exception

  Adapt the keys of this relation. Create them if they do not exist yet. Only call this method for many-to-many relations.

  Parameters:
    `fromConceptAttribs` -
    `toConceptAttribs` -
    `crossToFromKeyNames` -
    `crossToToKeyNames` -
  Throws:
    `M4Exception`

### changeFromAndToKeys

    void changeFromAndToKeys(java.util.Collection fromConceptAttribs,
                             java.util.Collection toConceptAttribs)
                             throws M4Exception

  Adapt the keys of this relation. Create them if they do not exist yet. Only call this method for one-to-many relations.

  Parameters:
    `fromConceptAttribs` -
    `toConceptAttribs` -
  Throws:
    `M4Exception`

### isOneToManyRelation

    boolean isOneToManyRelation()

  Returns true iff this Relation models a 1:n relationship.

### isManyToManyRelation

    boolean isManyToManyRelation()

  Returns true iff this Relation models an n:m relationship.

### isRelationallyValid

    boolean isRelationallyValid()

  This method returns information about the relational validity of the object. The relational validity is managed at the database level by triggers. The returned value denotes if the object is valid on the relational level or not.

### getSubRelations

    java.util.Collection getSubRelations()

### getSuperRelation

    Relation getSuperRelation()

### setSuperRelation

    void setSuperRelation(Relation superRelationship)
                          throws M4Exception

  Throws:
    `M4Exception`

### removeSuperRelation

    void removeSuperRelation()
                             throws M4Exception

  Remove the link to the superRelationship. The superRelationship itself is not removed.

  Throws:
    `M4Exception`

### addSubRelationship

    void addSubRelationship(Relation relationship)
                            throws M4Exception

  Throws:
    `M4Exception`

### getSubRelation

    Relation getSubRelation(java.lang.String name)

### getAllSubRelationships

    java.util.Collection getAllSubRelationships()

### removeSubRelationship

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

  Throws:
    `M4Exception`

### removeAllSubRelationships

    void removeAllSubRelationships()
                                   throws M4Exception

  Throws:
    `M4Exception`

### createCrossLinkColumnset

    Columnset createCrossLinkColumnset(java.lang.String name,
                                       java.lang.String schema,
                                       java.lang.String type)
                                       throws M4Exception

  Creates a ColumnSet that will be connected to this Relation. The name of the ColumnSet must be unique for this Relation.

  Parameters:
    `name` - The name for the new ColumnSet.
  Returns:
    The new ColumnSet object.
  Throws:
    `M4Exception` - when an error occurs during creation of the object.

### removeCrossLinkColumnset

    void removeCrossLinkColumnset()
                                  throws M4Exception

  Removes the ColumnSet for this Relation. It is also removed from the M4 Schema.

  Throws:
    `M4Exception`

### setM2mKeys

    void setM2mKeys(ForeignKey fromFK,
                    ForeignKey toFK)
                    throws M4Exception

  Sets the key fields that define a many-to-many relationship on the relational level for this Relationship. For a many-to-many relationship a ColumnSet and two foreignKeys are needed. The ColumnSet represents the crosstable needed to implement the many-to-many relationship. The crosstable ColumnSet is bound to this Relationship with the createColumnSet method.

  The foreignKey of the ColumnSet of the fromConcept is set as the fromKey. The foreignKey of the ColumnSet of the toConcept is set as the toKey.

  Parameters:
    `fromFK` - The foreignKey corresponding to the FromConcept.
    `toFK` - The foreignKey corresponding to the ToConcept.
  Throws:
    `StorageException` - If key doesn't exist yet, this exception may be propagated from ForeignKey.store().
    `M4Exception`

### copy

    Relation copy(Concept fromConcept,
                  Concept toConcept)
                  throws M4Exception

  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