|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface RelationManager
This interface represents a relation constraint. More specifically, it represents a relation manager (itself a node manager) as it applies between a node belonging to two other node managers. Some of the information here is retrieved from the NodeManager used to build the catual relation node (the data as described in the xml builder config file). This NodeManager is also referred to as the parent. Other data is retrieved from a special (hidden) object that decsribes what relations apply between two nodes. (formerly known as the TypeRel builder). This includes direction and cardinality, and the NodeManagers of nodes itself. These fields cannot be changed except through the use of an administration module. This interface is therefore not a real mmbase 'object' in itself - it exists of two objects joined together.
| Field Summary | |
|---|---|
static int |
BIDIRECTIONAL
Directionality constant : bi-directional |
static int |
UNIDIRECTIONAL
Directionality constant : uni-directional |
| Fields inherited from interface org.mmbase.bridge.NodeManager |
|---|
GUI_PLURAL, GUI_SINGULAR, ORDER_CREATE, ORDER_EDIT, ORDER_LIST, ORDER_NONE, ORDER_SEARCH |
| Fields inherited from interface org.mmbase.bridge.Node |
|---|
CLOUD_COMMITNODE_KEY |
| Method Summary | |
|---|---|
Relation |
createRelation(Node sourceNode,
Node destinationNode)
Adds a relation from this type. |
Relation |
createRelation(Node sourceNode,
RelationManager relationManager)
This method from Node is redeclared here to prevent an ambiguous invocation of method. |
NodeManager |
getDestinationManager()
Retrieves the type of node that can act as the destination of a relation of this type. |
int |
getDirectionality()
Retrieves the directionality for this type (the default assigned to a new relation). |
String |
getForwardGUIName()
Retrieves the gui name (prompt) of the role from source to destination |
String |
getForwardRole()
Retrieves the role of the source to the destination |
String |
getReciprocalGUIName()
Retrieves the gui name (prompt) of the role from destination to source |
String |
getReciprocalRole()
Retrieves the role of the destination to the source |
RelationList |
getRelations(Node node)
Retrieves all the relations of this type from a given node. |
NodeManager |
getSourceManager()
Retrieves the NodeManager of node that can act as the source of a relation of this type. |
boolean |
mayCreateRelation(Node sourceNode,
Node destinationNode)
Check if the current user may create a new relation of this type between the specified nodes. |
| Methods inherited from interface org.mmbase.bridge.NodeManager |
|---|
createFieldList, createNode, createNodeList, createQuery, createRelationList, getAllowedRelations, getAllowedRelations, getAllowedRelations, getCloud, getDescendants, getDescription, getDescription, getField, getFields, getFields, getGUIName, getGUIName, getGUIName, getInfo, getInfo, getList, getList, getList, getList, getName, getParent, getProperties, getProperty, hasField, mayCreateNode |
| Methods inherited from interface java.lang.Comparable |
|---|
compareTo |
| Field Detail |
|---|
static final int UNIDIRECTIONAL
static final int BIDIRECTIONAL
| Method Detail |
|---|
String getForwardRole()
StringString getReciprocalRole()
StringString getForwardGUIName()
StringString getReciprocalGUIName()
Stringint getDirectionality()
NodeManager getSourceManager()
NodeManager getDestinationManager()
Relation createRelation(Node sourceNode,
Node destinationNode)
sourceNode - the node from which you want to relatedestinationNode - the node to which you want to relate
Relation createRelation(Node sourceNode,
RelationManager relationManager)
createRelation in interface NodesourceNode - source node of the relationrelationManager - relation manager of the relation
RelationList getRelations(Node node)
Node.getRelations(String, NodeManager, String).
node - the node from which to give the relations
boolean mayCreateRelation(Node sourceNode,
Node destinationNode)
sourceNode - source node of the relationdestinationNode - destination node of the relation
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||