Class AbstractGraphElement<O>
java.lang.Object
kieker.tools.trace.analysis.filter.visualization.graph.AbstractGraphElement<O>
- Type Parameters:
O- The type of the objects which caused the creation of this graph element
- Direct Known Subclasses:
AbstractEdge,AbstractVertex
public abstract class AbstractGraphElement<O>
extends java.lang.Object
Superclass for graph elements, i.e. edges and vertices, in the visualization package.
- Since:
- 1.6
-
Constructor Summary
Constructors Modifier Constructor Description protectedAbstractGraphElement(O origin, IOriginRetentionPolicy originPolicy)This constructor initializes the element based on the given parameters. -
Method Summary
Modifier and Type Method Description voidaddOrigin(O origin)Adds a new origin object to this element.ColorgetColor()Returns this graph element's color.java.lang.StringgetDescription()Returns this graph element's description.abstract java.lang.StringgetIdentifier()Returns an identifier for this graph element (e.g., a label).java.util.Set<O>getOrigins()Returns the objects which caused the creation of this element.voidsetColor(Color color)Sets this graph element's color.voidsetDescription(java.lang.String description)Sets this graph element's description.
-
Constructor Details
-
AbstractGraphElement
This constructor initializes the element based on the given parameters.- Parameters:
origin- The origin of this element.originPolicy- The origin policy of this element.
-
-
Method Details
-
getColor
Returns this graph element's color.- Returns:
- See above
-
setColor
Sets this graph element's color.- Parameters:
color- The color to set
-
getDescription
public java.lang.String getDescription()Returns this graph element's description.- Returns:
- See above
-
setDescription
public void setDescription(java.lang.String description)Sets this graph element's description.- Parameters:
description- The description to set
-
getOrigins
Returns the objects which caused the creation of this element.- Returns:
- See above
-
addOrigin
Adds a new origin object to this element.- Parameters:
origin- The origin object
-
getIdentifier
public abstract java.lang.String getIdentifier()Returns an identifier for this graph element (e.g., a label).- Returns:
- An identifier or
nullif no identifier can be determined
-