|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectagg.xt_basis.TypeImpl
agg.xt_basis.ArcTypeImpl
public class ArcTypeImpl
This new class still not used! The type of a edge object is here defined.
Field Summary |
---|
Fields inherited from interface agg.xt_basis.Type |
---|
UNDEFINED |
Constructor Summary | |
---|---|
protected |
ArcTypeImpl()
this value will be true, if a graphobject inside of a type graph was defined. |
protected |
ArcTypeImpl(AttrType at)
creates a new type with the given attributes and an empty name. |
protected |
ArcTypeImpl(AttrType at,
java.lang.String stringRepr)
Creates a new type with the given attributes and the given name. |
protected |
ArcTypeImpl(java.lang.String stringRepr)
Creates a new type with the given name. |
Method Summary | |
---|---|
protected void |
adaptTypeAttribute(Type type)
Adds those attribute members of the specified Type type which are not found in this type. |
boolean |
addTypeGraphObject(GraphObject nodeOrArc)
Add the given GraphObject of a type graph to this type. |
void |
addTypeUser(GraphObject nodeOrArc)
Add the specified GraphObject nodeOrArc: in case of Node - to my TypeGraphNode and in case of Arc - to my TypeGraphArc of a TypeGraph, if it exists. |
void |
addTypeUser(GraphObject nodeOrArc,
Graph g)
Add the specified GraphObject nodeOrArc: in case of Node - to my TypeGraphNode and in case of Arc - to my TypeGraphArc of a TypeGraph, if it exists. |
protected void |
addUser(Arc arc)
Add the specified arc to my container of graph objects. |
protected void |
addUser(Node node)
Add the specified node to my container of graph objects. |
void |
addUsingGraphObject(GraphObject nodeOrArc)
Deprecated. replaced by addTypeUser(GraphObject nodeOrArc) |
void |
addUsingGraphObject(GraphObject nodeOrArc,
Graph g)
Deprecated. replaced by addTypeUser(GraphObject nodeOrArc, Graph g) |
TypeError |
check(Arc arc,
int level)
Returns null, if the specified arc is valid typed as defined in the type graph. |
TypeError |
check(GraphObject nodeOrArc,
int level)
returns if the given GraphObject is valid typed as defined in the type graph. |
TypeError |
check(Node node,
int level)
returns if the given Node is valid typed as defined in the type graph. |
java.util.Vector<java.lang.String> |
checkDoubleAttributeName(Type otherType)
|
protected void |
checkDoubleAttributeType()
|
TypeError |
checkIfEdgeCreatable(Graph g,
Node src,
Node tar,
int level)
|
TypeError |
checkIfEdgeCreatable(Node src,
Node tar,
int level)
|
TypeError |
checkIfRemovable(Node node,
int level)
The spcified node must be an instance of my. |
TypeError |
checkIfRemovableFromSource(GraphObject node,
Arc arc,
int level)
returns if the given arc could be removed from the given node so the node would be valid typed. |
TypeError |
checkIfRemovableFromTarget(GraphObject node,
Arc arc,
int level)
returns if the given arc could be removed from the given node so the node would be valid typed. |
protected TypeError |
checkSourceMax(Graph g,
Node src,
Node tar)
|
protected TypeError |
checkTargetMax(Graph g,
Node src,
Node tar)
|
TypeError |
checkTargetMin(GraphObject tarnode,
Arc arc)
|
boolean |
compareTo(Type t)
Returns TRUE if this type is equal to the type t. |
boolean |
compareTypeGraphArcs(Type t)
|
boolean |
compareTypeGraphArcsMultiplicity(Type t)
|
java.lang.String |
convertToKey()
Returns result string of this.getStringRepr()+this.getAdditionalRepr() |
void |
createAttributeType()
|
boolean |
differentTo(Type t,
java.util.Vector<java.lang.String> difference)
Returns TRUE if this type is different to the type t. |
java.util.Vector<Type> |
getAllChildren()
returns a list with all the children of the current type and itself as the first element |
java.util.Vector<Type> |
getAllParents()
returns a list with all the parents of the current type and itself as the first element |
protected java.util.HashMap<Type,java.util.HashMap<Type,agg.xt_basis.TypeGraphArc>> |
getArcTypeGraphObjects()
|
java.util.Vector<Arc> |
getIncomingArcs()
Returns all incoming arcs (of my own and of my parents) on condition that a type graph is defined, otherwise returns an empty vector. |
java.util.Vector<Type> |
getIncomingArcTypes()
Returns all incoming arc types (of my own and of my parents) on condition that a type graph is defined, otherwise returns an empty vector. |
int |
getMaxMultiplicityOfAllChildren()
|
int |
getMinMultiplicityOfAllChildren()
|
java.lang.String |
getName()
internal function to convert a type into a string. |
java.util.Vector<Arc> |
getOutgoingArcs()
Returns all outgoing arcs (of my own and of my parents) on condition that a type graph is defined, otherwise returns an empty vector. |
java.util.Vector<Type> |
getOutgoingArcTypes()
Returns all outgoing arc types (of my own and of my parents) on condition that a type graph is defined, otherwise returns an empty vector. |
java.util.Vector<Arc> |
getOwnIncomingArcs()
Returns my own incoming arcs on condition that a type graph is defined, otherwise returns an empty vector. |
java.util.Vector<Type> |
getOwnIncomingArcTypes()
Returns my own incoming arc types on condition that a type graph is defined, otherwise returns an empty vector. |
java.util.Vector<Arc> |
getOwnOutgoingArcs()
Returns my own outgoing arcs on condition that a type graph is defined, otherwise returns an empty vector. |
java.util.Vector<Type> |
getOwnOutgoingArcTypes()
Returns my own outgoing arc types on condition that a type graph is defined, otherwise returns an empty vector. |
protected agg.xt_basis.TypeGraphArc |
getSimilarTypeGraphArc(Type sourceType,
Type targetType)
|
int |
getSourceMax()
Return the max of the multiplicity of a node type. |
int |
getSourceMax(Type sourceType,
Type targetType)
Return the max of the source multiplicity of an edge type. |
int |
getSourceMin()
Return the min of the multiplicity of a node type. |
int |
getSourceMin(Type sourceType,
Type targetType)
Return the min of the source multiplicity of an edge type. |
int |
getTargetMax(Type sourceType,
Type targetType)
Return the max of the target multiplicity of an edge type. |
int |
getTargetMin(Type sourceType,
Type targetType)
Return the min of the target multiplicity of an edge type. |
java.util.Vector<Type> |
getTargetsOfArc(Type sourceType)
Searchs for a type that is the target type of this edge type with the specified source type. |
protected agg.xt_basis.TypeGraphArc |
getTypeGraphArc(Type sourceType,
Type targetType)
Returns the subtype object for this source and target combination. |
Arc |
getTypeGraphArcObject(Type sourceType,
Type targetType)
returns a type graph edge, if it is defined. |
protected agg.xt_basis.TypeGraphNode |
getTypeGraphNode()
Returns the subtype object for this node type. |
Node |
getTypeGraphNodeObject()
returns the type graph node, if it is defined. |
java.util.Vector<GraphObject> |
getTypeUsers()
|
java.util.Vector<GraphObject> |
getUsingGraphObjects()
Deprecated. replaced by getTypeUsers() |
boolean |
hasTypeGraphArc()
|
boolean |
hasTypeGraphArc(GraphObject sourceType,
GraphObject targetType)
|
boolean |
hasTypeGraphArc(Type sourceType)
Returns true if at least one edge exists from the specified source type to any other type, otherwise false. |
boolean |
hasTypeGraphArc(Type sourceType,
Type targetType)
|
boolean |
hasTypeGraphNode()
returns true, if there is an object in the type graph for this type. |
boolean |
isAbstract()
|
boolean |
isArcType()
|
boolean |
isChildOf(Type t)
compares the specified type with parents of this object |
boolean |
isChildTypeGraphNodeUsed()
|
boolean |
isChildTypeUsed()
|
boolean |
isEdgeCreatable(Type sourceType,
Type targetType,
int level)
|
boolean |
isNodeType()
|
boolean |
isParentOf(Type t)
compares the given type and its ancestors with this object |
boolean |
isRelatedTo(Type t)
Finds out if there is any relation between this type and the given one. |
boolean |
isTypeGraphArcUsed(Arc arc)
|
boolean |
isTypeGraphNodeUsed()
|
boolean |
isTypeGraphObjectDefined()
returns true, if there is at least one object in the type graph for this type. |
boolean |
isTypeUsed()
|
void |
removeAllTypeGraphObjects()
Remove type graph objects from this type. |
boolean |
removeTypeGraphObject(GraphObject nodeOrArc)
Remove the given GraphObject from the type graph and from this type. |
void |
removeTypeUser(GraphObject nodeOrArc)
Remove the specified GraphObject nodeOrArc: in case of Node - from my TypeGraphNode and in case of Arc - from my TypeGraphArc of a TypeGraph, if it exists. |
protected void |
removeUser(Arc arc)
Remove the specified arc from my container of graph objects. |
protected void |
removeUser(Node node)
Remove the specified node from my container of graph objects. |
void |
removeUsingGraphObject(GraphObject nodeOrArc)
Deprecated. replaced by removeTypeUser(GraphObject nodeOrArc) |
void |
setAbstract(boolean b)
|
void |
setAdditionalRepr(java.lang.String repr)
set an additional graphical string, which is saved together with the name string representation. |
void |
setAttributeType(AttrType at)
|
void |
setSourceMax(int value)
Set the max of the multiplicity of a node type to the value. |
void |
setSourceMax(Type sourceType,
Type targetType,
int value)
Set the max of the source multiplicity of an edge type to the value. |
void |
setSourceMin(int value)
Set the min of the multiplicity of a node type to the value. |
void |
setSourceMin(Type sourceType,
Type targetType,
int value)
Set the min of the source multiplicity of an edge type to the value. |
void |
setTargetMax(Type sourceType,
Type targetType,
int value)
Set the max of the target multiplicity of an edge type to the value. |
void |
setTargetMin(Type sourceType,
Type targetType,
int value)
Set the min of the target multiplicity of an edge type to the value. |
void |
showAllRelatives()
|
void |
showRelatives()
|
void |
XreadObject(XMLHelper h)
|
void |
XwriteObject(XMLHelper h)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
protected ArcTypeImpl()
protected ArcTypeImpl(java.lang.String stringRepr)
stringRepr
- the name of the typeprotected ArcTypeImpl(AttrType at, java.lang.String stringRepr)
at
- the declaration of the attributesstringRepr
- the name of the typeprotected ArcTypeImpl(AttrType at)
at
- the declaration of the attributesMethod Detail |
---|
public void createAttributeType()
createAttributeType
in class TypeImpl
public void setAttributeType(AttrType at)
setAttributeType
in class TypeImpl
public boolean isNodeType()
isNodeType
in interface Type
isNodeType
in class TypeImpl
public boolean isArcType()
isArcType
in interface Type
isArcType
in class TypeImpl
public java.lang.String convertToKey()
TypeImpl
this.getStringRepr()+this.getAdditionalRepr()
convertToKey
in interface Type
convertToKey
in class TypeImpl
getStringRepr()
and getAdditionalRepr()
protected void adaptTypeAttribute(Type type)
adaptTypeAttribute
in class TypeImpl
protected void checkDoubleAttributeType()
checkDoubleAttributeType
in class TypeImpl
public boolean compareTo(Type t)
compareTo
in interface Type
compareTo
in class TypeImpl
public boolean differentTo(Type t, java.util.Vector<java.lang.String> difference)
differentTo
in class TypeImpl
public void setAbstract(boolean b)
setAbstract
in interface Type
setAbstract
in class TypeImpl
public boolean isAbstract()
isAbstract
in interface Type
isAbstract
in class TypeImpl
public boolean isChildOf(Type t)
isChildOf
in interface Type
isChildOf
in class TypeImpl
public boolean isParentOf(Type t)
isParentOf
in interface Type
isParentOf
in class TypeImpl
public boolean isRelatedTo(Type t)
isRelatedTo
in interface Type
isRelatedTo
in class TypeImpl
public java.util.Vector<Type> getAllParents()
getAllParents
in interface Type
getAllParents
in class TypeImpl
public java.util.Vector<Type> getAllChildren()
getAllChildren
in interface Type
getAllChildren
in class TypeImpl
public int getMaxMultiplicityOfAllChildren()
getMaxMultiplicityOfAllChildren
in class TypeImpl
public int getMinMultiplicityOfAllChildren()
getMinMultiplicityOfAllChildren
in class TypeImpl
public void showRelatives()
showRelatives
in class TypeImpl
public void showAllRelatives()
showAllRelatives
in class TypeImpl
public java.util.Vector<java.lang.String> checkDoubleAttributeName(Type otherType)
checkDoubleAttributeName
in class TypeImpl
public void setAdditionalRepr(java.lang.String repr)
setAdditionalRepr
in interface Type
setAdditionalRepr
in class TypeImpl
public void XwriteObject(XMLHelper h)
XwriteObject
in interface XMLObject
XwriteObject
in class TypeImpl
public void XreadObject(XMLHelper h)
XreadObject
in interface XMLObject
XreadObject
in class TypeImpl
public java.lang.String getName()
TypeImpl.getStringRepr()
)
getName
in interface Type
getName
in class TypeImpl
public TypeError check(GraphObject nodeOrArc, int level)
check
in interface Type
check
in class TypeImpl
nodeOrArc
- the object to testlevel
- a type graph check level, as defined in
TypeSet.setLevelOfTypeGraphCheck(int)
TypeError
if there was a mismatchpublic TypeError check(Node node, int level)
check
in class TypeImpl
TypeError
if there was a mismatchpublic boolean hasTypeGraphArc(Type sourceType)
hasTypeGraphArc
in class TypeImpl
public java.util.Vector<Type> getTargetsOfArc(Type sourceType)
getTargetsOfArc
in class TypeImpl
public boolean isEdgeCreatable(Type sourceType, Type targetType, int level)
isEdgeCreatable
in class TypeImpl
public TypeError check(Arc arc, int level)
check
in class TypeImpl
TypeError
if there was a mismatchpublic TypeError checkIfEdgeCreatable(Node src, Node tar, int level)
checkIfEdgeCreatable
in class TypeImpl
public TypeError checkIfEdgeCreatable(Graph g, Node src, Node tar, int level)
checkIfEdgeCreatable
in class TypeImpl
protected TypeError checkSourceMax(Graph g, Node src, Node tar)
checkSourceMax
in class TypeImpl
protected TypeError checkTargetMax(Graph g, Node src, Node tar)
checkTargetMax
in class TypeImpl
public boolean addTypeGraphObject(GraphObject nodeOrArc)
addTypeGraphObject
in interface Type
addTypeGraphObject
in class TypeImpl
public boolean removeTypeGraphObject(GraphObject nodeOrArc)
removeTypeGraphObject
in interface Type
removeTypeGraphObject
in class TypeImpl
public void removeAllTypeGraphObjects()
removeAllTypeGraphObjects
in interface Type
removeAllTypeGraphObjects
in class TypeImpl
public java.util.Vector<GraphObject> getUsingGraphObjects()
getTypeUsers()
getUsingGraphObjects
in class TypeImpl
public java.util.Vector<GraphObject> getTypeUsers()
getTypeUsers
in interface Type
getTypeUsers
in class TypeImpl
public void addUsingGraphObject(GraphObject nodeOrArc)
addUsingGraphObject
in interface Type
addUsingGraphObject
in class TypeImpl
public void addTypeUser(GraphObject nodeOrArc)
addTypeUser
in interface Type
addTypeUser
in class TypeImpl
nodeOrArc
- public void addUsingGraphObject(GraphObject nodeOrArc, Graph g)
addUsingGraphObject
in interface Type
addUsingGraphObject
in class TypeImpl
protected void addUser(Node node)
addUser
in class TypeImpl
node
- protected void removeUser(Node node)
removeUser
in class TypeImpl
node
- protected void addUser(Arc arc)
addUser
in class TypeImpl
arc
- protected void removeUser(Arc arc)
removeUser
in class TypeImpl
arc
- public void addTypeUser(GraphObject nodeOrArc, Graph g)
addTypeUser
in interface Type
addTypeUser
in class TypeImpl
nodeOrArc
- g
- is the context graph of the nodeOrArcpublic void removeUsingGraphObject(GraphObject nodeOrArc)
removeUsingGraphObject
in interface Type
removeUsingGraphObject
in class TypeImpl
public void removeTypeUser(GraphObject nodeOrArc)
removeTypeUser
in interface Type
removeTypeUser
in class TypeImpl
nodeOrArc
- public void setSourceMin(Type sourceType, Type targetType, int value)
setSourceMin
in interface Type
setSourceMin
in class TypeImpl
public void setSourceMax(Type sourceType, Type targetType, int value)
setSourceMax
in interface Type
setSourceMax
in class TypeImpl
public void setTargetMin(Type sourceType, Type targetType, int value)
setTargetMin
in interface Type
setTargetMin
in class TypeImpl
public void setTargetMax(Type sourceType, Type targetType, int value)
setTargetMax
in interface Type
setTargetMax
in class TypeImpl
public int getSourceMin(Type sourceType, Type targetType)
getSourceMin
in interface Type
getSourceMin
in class TypeImpl
public int getSourceMax(Type sourceType, Type targetType)
getSourceMax
in interface Type
getSourceMax
in class TypeImpl
public int getTargetMin(Type sourceType, Type targetType)
getTargetMin
in interface Type
getTargetMin
in class TypeImpl
public int getTargetMax(Type sourceType, Type targetType)
getTargetMax
in interface Type
getTargetMax
in class TypeImpl
public void setSourceMin(int value)
setSourceMin
in interface Type
setSourceMin
in class TypeImpl
public void setSourceMax(int value)
setSourceMax
in interface Type
setSourceMax
in class TypeImpl
public int getSourceMin()
getSourceMin
in interface Type
getSourceMin
in class TypeImpl
public int getSourceMax()
getSourceMax
in interface Type
getSourceMax
in class TypeImpl
public Arc getTypeGraphArcObject(Type sourceType, Type targetType)
Type
getTypeGraphArcObject
in interface Type
getTypeGraphArcObject
in class TypeImpl
protected agg.xt_basis.TypeGraphArc getTypeGraphArc(Type sourceType, Type targetType)
getTypeGraphArc
in class TypeImpl
protected agg.xt_basis.TypeGraphArc getSimilarTypeGraphArc(Type sourceType, Type targetType)
getSimilarTypeGraphArc
in class TypeImpl
public boolean hasTypeGraphArc()
hasTypeGraphArc
in interface Type
hasTypeGraphArc
in class TypeImpl
public boolean hasTypeGraphArc(Type sourceType, Type targetType)
hasTypeGraphArc
in class TypeImpl
public boolean hasTypeGraphArc(GraphObject sourceType, GraphObject targetType)
hasTypeGraphArc
in class TypeImpl
protected java.util.HashMap<Type,java.util.HashMap<Type,agg.xt_basis.TypeGraphArc>> getArcTypeGraphObjects()
getArcTypeGraphObjects
in class TypeImpl
public boolean compareTypeGraphArcs(Type t)
compareTypeGraphArcs
in class TypeImpl
public boolean compareTypeGraphArcsMultiplicity(Type t)
compareTypeGraphArcsMultiplicity
in class TypeImpl
protected agg.xt_basis.TypeGraphNode getTypeGraphNode()
getTypeGraphNode
in class TypeImpl
public boolean hasTypeGraphNode()
hasTypeGraphNode
in interface Type
hasTypeGraphNode
in class TypeImpl
public boolean isTypeGraphNodeUsed()
isTypeGraphNodeUsed
in class TypeImpl
public boolean isChildTypeGraphNodeUsed()
isChildTypeGraphNodeUsed
in class TypeImpl
public boolean isTypeGraphArcUsed(Arc arc)
isTypeGraphArcUsed
in class TypeImpl
public boolean isTypeUsed()
isTypeUsed
in class TypeImpl
public boolean isChildTypeUsed()
isChildTypeUsed
in class TypeImpl
public Node getTypeGraphNodeObject()
getTypeGraphNodeObject
in interface Type
getTypeGraphNodeObject
in class TypeImpl
public java.util.Vector<Type> getOwnOutgoingArcTypes()
getOwnOutgoingArcTypes
in class TypeImpl
public java.util.Vector<Type> getOutgoingArcTypes()
getOutgoingArcTypes
in class TypeImpl
public java.util.Vector<Arc> getOwnOutgoingArcs()
getOwnOutgoingArcs
in class TypeImpl
public java.util.Vector<Arc> getOutgoingArcs()
getOutgoingArcs
in class TypeImpl
public java.util.Vector<Type> getOwnIncomingArcTypes()
getOwnIncomingArcTypes
in class TypeImpl
public java.util.Vector<Type> getIncomingArcTypes()
getIncomingArcTypes
in class TypeImpl
public java.util.Vector<Arc> getOwnIncomingArcs()
getOwnIncomingArcs
in class TypeImpl
public java.util.Vector<Arc> getIncomingArcs()
getIncomingArcs
in class TypeImpl
public boolean isTypeGraphObjectDefined()
isTypeGraphObjectDefined
in interface Type
isTypeGraphObjectDefined
in class TypeImpl
public TypeError checkIfRemovableFromSource(GraphObject node, Arc arc, int level)
Type
checkIfRemovableFromSource
in interface Type
checkIfRemovableFromSource
in class TypeImpl
node
- the node which will be modified. This node has to be the
source of the arc and has to have this type.arc
- the arc which will be removedlevel
- the actual level. If not set to
TypeSet.ENABLED_MAX_MIN
this method will do nothing.
TypeError
containing the possible fault.public TypeError checkIfRemovableFromTarget(GraphObject node, Arc arc, int level)
Type
checkIfRemovableFromTarget
in interface Type
checkIfRemovableFromTarget
in class TypeImpl
node
- the node which will be modified. This node has to be the
target of the arc and has to have this type.arc
- the arc which will be removedlevel
- the actual level. If not set to
TypeSet.ENABLED_MAX_MIN
this method will do nothing.
TypeError
containing the possible fault.public TypeError checkTargetMin(GraphObject tarnode, Arc arc)
public TypeError checkIfRemovable(Node node, int level)
checkIfRemovable
in interface Type
checkIfRemovable
in class TypeImpl
node
- the node which will be removed.level
- the actual level. If not set to
TypeSet.ENABLED_MAX_MIN
this method will do nothing.
TypeError
containing the possible fault.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |