mapss.dif.psdf
Class PSDFSpecificationGraph

java.lang.Object
  extended by mocgraph.Graph
      extended by mocgraph.DirectedGraph
          extended by mapss.dif.DIFGraph
              extended by mapss.dif.psdf.PSDFSpecificationGraph
All Implemented Interfaces:
java.lang.Cloneable

public class PSDFSpecificationGraph
extends DIFGraph

Information associated with a PSDFSpecification graph. PSDF specification has only three subgraphs: init, subinit, body. The PSDFSpecificationGraph is used as the base graph for PSDFSpecification (which extends DIFGraph). When initiate the PSDFSpecificationGraph, it will automatically add three supernodes: init, subinit, body. Any modification on graph topology such as addNode or addEdge are not allowed in this class.

Version:
$Id: PSDFSpecificationGraph.java 409 2007-05-13 19:47:16Z plishker $
Author:
Chia-Jui Hsu
See Also:
PSDFSpecification

Constructor Summary
PSDFSpecificationGraph()
          Construct a PSDFSpecificationGraph with init, subinint, and body nodes.
 
Method Summary
protected  void _registerEdge(mocgraph.Edge edge)
          Register a new edge in the graph.
protected  void _registerNode(mocgraph.Node node)
          Register a new node in the graph.
 PSDFAttributeType getGraphType()
           
 void setGraphType(PSDFAttributeType type)
          set type to either PSDFAttributeType.InitGraph, PSDFAttributeType.SubinitGraph, PSDFAttributeType.BodyGraph, or PSDFAttributeType.PSDFSpecification.
 boolean validEdgeWeight(java.lang.Object weight)
          Verify edge weight for PSDFSpecificationGraph.
 boolean validNodeWeight(java.lang.Object weight)
          Verify node weight for PSDF graph.
 
Methods inherited from class mapss.dif.DIFGraph
_getAttributeContainer, _removeAttributeContainer, _removeReferenceFromAttributes, _setAttributeContainer, addEdge, addEdge, equals, getAttribute, getAttribute, getAttributeByContent, getAttributeByContent, getAttributeDescriptions, getAttributeDescriptions, getAttributeNames, getAttributeNames, getAttributes, getAttributes, getAttributesByContent, getAttributesByContent, getEdge, getName, getName, getNode, getObject, getParameter, getParameterNames, getParameters, hashCode, hideEdge, mergeGraph, mirror, mirror, removeAllAttributes, removeAllAttributes, removeAttribute, removeAttribute, removeAttribute, removeAttribute, removeEdge, removeNode, removeParameter, restoreEdge, setAttribute, setAttribute, setName, setName, setParameter, subgraph, subgraph
 
Methods inherited from class mocgraph.DirectedGraph
_connect, _connectedSubGraph, _disconnect, _initializeAnalyses, backwardReachableNodes, backwardReachableNodes, backwardReachableNodes, backwardReachableNodes, cycleNodeCollection, cycleNodes, edgeExists, edgeExists, inputEdgeCount, inputEdges, isAcyclic, outputEdgeCount, outputEdges, predecessorEdges, predecessors, reachableNodes, reachableNodes, reachableNodes, reachableNodes, sccDecomposition, selfLoopEdgeCount, sinkNodeCount, sinkNodes, sourceNodeCount, sourceNodes, subgraphs, successorEdges, successors, toDirectedAcyclicGraph, topologicalSort, topologicalSort, transitiveClosure
 
Methods inherited from class mocgraph.Graph
_addEdge, _connectEdge, _disconnectEdge, _emptyGraph, _registerChange, addAnalysis, addEdge, addEdge, addEdge, addEdges, addGraph, addNode, addNode, addNodes, addNodeWeight, addNodeWeights, changeCount, clone, cloneAs, connectedComponents, containsEdge, containsEdgeWeight, containsNode, containsNodeWeight, edge, edge, edgeCount, edgeLabel, edgeLabel, edges, edges, edges, edgeWeight, hidden, hiddenEdgeCount, hiddenEdges, incidentEdgeCount, incidentEdges, neighborEdges, neighbors, node, node, nodeCount, nodeLabel, nodeLabel, nodes, nodes, nodes, nodeWeight, selfLoopEdgeCount, selfLoopEdges, selfLoopEdges, toString, validateWeight, validateWeight, validateWeight, validateWeight, weightArray
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

PSDFSpecificationGraph

public PSDFSpecificationGraph()
Construct a PSDFSpecificationGraph with init, subinint, and body nodes.

Method Detail

getGraphType

public PSDFAttributeType getGraphType()

setGraphType

public void setGraphType(PSDFAttributeType type)
set type to either PSDFAttributeType.InitGraph, PSDFAttributeType.SubinitGraph, PSDFAttributeType.BodyGraph, or PSDFAttributeType.PSDFSpecification.

Parameters:
type - PSDFAttributeType

validEdgeWeight

public boolean validEdgeWeight(java.lang.Object weight)
Verify edge weight for PSDFSpecificationGraph. It always returns false, because PSDF specification has no edges.

Overrides:
validEdgeWeight in class DIFGraph
Parameters:
weight - The edge weight to verify.
Returns:
True if the given edge weight is valid for a PSDF graph.

validNodeWeight

public boolean validNodeWeight(java.lang.Object weight)
Verify node weight for PSDF graph.

Overrides:
validNodeWeight in class DIFGraph
Parameters:
weight - The node weight to verify.
Returns:
True if the given node weight is valid for a PSDF graph.

_registerEdge

protected void _registerEdge(mocgraph.Edge edge)
Description copied from class: DIFGraph
Register a new edge in the graph. The edge is assumed to be non-null, unique, and consistent with the node set.

Overrides:
_registerEdge in class DIFGraph
Parameters:
edge - The new edge.

_registerNode

protected void _registerNode(mocgraph.Node node)
Description copied from class: DIFGraph
Register a new node in the graph. The node is assumed to be non-null and unique.

Overrides:
_registerNode in class DIFGraph
Parameters:
node - The new node.