uk.ed.inf.graph.compound.archetypal
Class ArchetypalCompoundGraph

java.lang.Object
  extended by uk.ed.inf.graph.compound.base.BaseCompoundGraph
      extended by uk.ed.inf.graph.compound.archetypal.ArchetypalCompoundGraph
All Implemented Interfaces:
IBasicGraph<BaseCompoundNode,BaseCompoundEdge>, ICompoundGraph<BaseCompoundNode,BaseCompoundEdge>, IModifiableCompoundGraph<BaseCompoundNode,BaseCompoundEdge>, IDirectedGraph<BaseCompoundNode,BaseCompoundEdge>, IRestorableGraph<BaseCompoundNode,BaseCompoundEdge>
Direct Known Subclasses:
CompoundGraph

public abstract class ArchetypalCompoundGraph
extends BaseCompoundGraph


Constructor Summary
protected ArchetypalCompoundGraph(BaseGraphCopyBuilder copyBuilder)
           
protected ArchetypalCompoundGraph(BaseGraphCopyBuilder copyBuilder, ArchetypalCompoundGraph otherGraph)
           
 
Method Summary
protected abstract  void createCopyOfRootNode(int newIndexValue, BaseCompoundNode otherRootNode)
           
protected abstract  void createNewRootNode(int indexValue)
           
protected  IndexCounter getEdgeCounter()
           
protected  IndexCounter getNodeCounter()
           
protected  ITree<BaseCompoundNode> getNodeTree()
           
abstract  ArchetypalCompoundNode getRootNode()
          Get the root node of this graph.
protected  int getRootNodeIndex()
           
 
Methods inherited from class uk.ed.inf.graph.compound.base.BaseCompoundGraph
canCopyHere, canRemoveSubgraph, containsConnection, containsConnection, containsDirectedEdge, containsDirectedEdge, containsEdge, containsEdge, containsNode, containsNode, copyHere, edgeFactory, edgeIterator, getCopiedComponents, getCurrentState, getEdge, getNode, getNumEdges, getNumNodes, hasPassedAdditionalValidation, isValid, nodeFactory, nodeIterator, performCopy, removeSubgraph, restoreState, subgraphFactory
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ArchetypalCompoundGraph

protected ArchetypalCompoundGraph(BaseGraphCopyBuilder copyBuilder)

ArchetypalCompoundGraph

protected ArchetypalCompoundGraph(BaseGraphCopyBuilder copyBuilder,
                                  ArchetypalCompoundGraph otherGraph)
Method Detail

createNewRootNode

protected abstract void createNewRootNode(int indexValue)

createCopyOfRootNode

protected abstract void createCopyOfRootNode(int newIndexValue,
                                             BaseCompoundNode otherRootNode)
Specified by:
createCopyOfRootNode in class BaseCompoundGraph

getNodeTree

protected final ITree<BaseCompoundNode> getNodeTree()
Specified by:
getNodeTree in class BaseCompoundGraph

getRootNodeIndex

protected final int getRootNodeIndex()

getRootNode

public abstract ArchetypalCompoundNode getRootNode()
Description copied from interface: ICompoundGraph
Get the root node of this graph.

Specified by:
getRootNode in interface ICompoundGraph<BaseCompoundNode,BaseCompoundEdge>
Specified by:
getRootNode in class BaseCompoundGraph
Returns:
The root node, which cannot be null.

getNodeCounter

protected final IndexCounter getNodeCounter()
Specified by:
getNodeCounter in class BaseCompoundGraph

getEdgeCounter

protected final IndexCounter getEdgeCounter()
Specified by:
getEdgeCounter in class BaseCompoundGraph