org.graffiti.plugin.view
Interface GraphElementComponentInterface

All Known Subinterfaces:
EdgeComponentInterface, NodeComponentInterface
All Known Implementing Classes:
GraphElementComponent

public interface GraphElementComponentInterface


Method Summary
 void addAttributeComponent(Attribute attr, AttributeComponent ac)
          Adds an Attribute and its GraffitiViewComponent to the list of registered attributes that can be displayed.
 void addDependentComponent(GraphElementComponent comp)
          Adds a GraphElementComponent to the list of dependent GraphElementComponents.
 void attributeChanged(Attribute attr)
          Called when an attribute of the GraphElement represented by this component has changed.
 void clearAttributeComponentList()
          Removes all entries in the attributeComponent list.
 void clearDependentComponentList()
          Removes a GraphElementComponent from the list of dependent GraphElementComponents.
 void createNewShape()
          Called to initialise the shape of the NodeComponent correctly.
 void createStandardShape()
          Called to initialise and draw a standard shape, if the specified shapeclass could not be found.
 AttributeComponent getAttributeComponent(Attribute attr)
          Returns the attributeComponents of given attribute.
 Iterator<AttributeComponent> getAttributeComponentIterator()
          Returns the attributeComponents of given attribute.
 GraphElement getGraphElement()
          Returns the graphElement.
 GraphElementShape getShape()
          Returns GraphElementShape object
 void graphicAttributeChanged(Attribute attr)
          Called when a graphic attribute of the GraphElement represented by this component has changed.
 void nonGraphicAttributeChanged(Attribute attr)
          Called when a non-graphic attribute of the GraphElement represented by this component has changed.
 void removeAttributeComponent(Attribute attr)
          Removes a GraffitiViewComponent of an Attribute from collection of attribute components.
 void removeDependentComponent(GraphElementComponent comp)
          Removes a GraphElementComponent from the list of dependent GraphElementComponents.
 

Method Detail

getAttributeComponent

AttributeComponent getAttributeComponent(Attribute attr)
Returns the attributeComponents of given attribute.

Parameters:
attr -
Returns:
Map

getAttributeComponentIterator

Iterator<AttributeComponent> getAttributeComponentIterator()
Returns the attributeComponents of given attribute.

Returns:
Map

getGraphElement

GraphElement getGraphElement()
Returns the graphElement.

Returns:
GraphElement

getShape

GraphElementShape getShape()
Returns GraphElementShape object

Returns:
DOCUMENT ME!

addAttributeComponent

void addAttributeComponent(Attribute attr,
                           AttributeComponent ac)
Adds an Attribute and its GraffitiViewComponent to the list of registered attributes that can be displayed. This attribute is then treated as dependent on the position, size etc. of this GraphElement.

Parameters:
attr - the attribute that is registered as being able to be displayed.
ac - the component that will be used to display the attribute.

addDependentComponent

void addDependentComponent(GraphElementComponent comp)
Adds a GraphElementComponent to the list of dependent GraphElementComponents. These will nearly always be EdgeComponents that are dependent on their source or target nodes.

Parameters:
comp - the GraphElementComponent that is added to the list of dependent components.

attributeChanged

void attributeChanged(Attribute attr)
                      throws ShapeNotFoundException
Called when an attribute of the GraphElement represented by this component has changed.

Parameters:
attr - the attribute that has triggered the event.
Throws:
ShapeNotFoundException - DOCUMENT ME!

clearAttributeComponentList

void clearAttributeComponentList()
Removes all entries in the attributeComponent list.


clearDependentComponentList

void clearDependentComponentList()
Removes a GraphElementComponent from the list of dependent GraphElementComponents.


createNewShape

void createNewShape()
                    throws ShapeNotFoundException
Called to initialise the shape of the NodeComponent correctly. Also calls repaint().

Throws:
ShapeNotFoundException - thrown when the shapeclass couldn't be resolved.

createStandardShape

void createStandardShape()
Called to initialise and draw a standard shape, if the specified shapeclass could not be found.


graphicAttributeChanged

void graphicAttributeChanged(Attribute attr)
                             throws ShapeNotFoundException
Called when a graphic attribute of the GraphElement represented by this component has changed.

Parameters:
attr - the graphic attribute that has triggered the event.
Throws:
ShapeNotFoundException - DOCUMENT ME!

nonGraphicAttributeChanged

void nonGraphicAttributeChanged(Attribute attr)
                                throws ShapeNotFoundException
Called when a non-graphic attribute of the GraphElement represented by this component has changed.

Parameters:
attr - the attribute that has triggered the event.
Throws:
ShapeNotFoundException - DOCUMENT ME!

removeAttributeComponent

void removeAttributeComponent(Attribute attr)
Removes a GraffitiViewComponent of an Attribute from collection of attribute components.

Parameters:
attr - the attribute that has to be removed

removeDependentComponent

void removeDependentComponent(GraphElementComponent comp)
Removes a GraphElementComponent from the list of dependent GraphElementComponents.

Parameters:
comp - the GraphElementComponent that is removed from the list of dependent components.


Generated at 2012-05-30 11:00:36 PM CEST