com.googlecode.sarasvati.load
Interface GraphValidator

All Known Implementing Classes:
GraphValidatorAdapter

public interface GraphValidator

Interface containing methods which are invoked as part of the graph loading process. The methods may throw exceptions if the graph violates some user constraint.

Author:
Paul Lorenz Vincent Kirsch

Method Summary
 void validateArc(Arc arc)
          Allows user validation of each Arc in the loaded Graph.
 void validateArcDefinition(ArcDefinition arcDefinition)
          Allows user validation of each XmlArc in the XmlProcessDefinition being loaded.
 void validateExternalArcDefinition(ExternalArcDefinition externalArcDefinition)
          Allows user validation of each XmlExternalArc in the XmlProcessDefinition being loaded.
 void validateExternalDefinition(ExternalDefinition externalDefinition)
          Allows user validation of each XmlExternal in the XmlProcessDefinition being loaded.
 void validateGraph(Graph graph)
          Allows user validation of the loaded Graph, before it is added to the GraphRepository.
 void validateNode(Node node)
          Allows user validation of each Node in the loaded Graph.
 void validateNodeDefinition(NodeDefinition nodeDefinition)
          Allows user validation of each XmlNode in the XmlProcessDefinition being loaded.
 void validateProcessDefinition(ProcessDefinition processDefinition)
          Allows user validation of the xml process definition.
 

Method Detail

validateProcessDefinition

void validateProcessDefinition(ProcessDefinition processDefinition)
                               throws SarasvatiLoadException
Allows user validation of the xml process definition. This is invoked at the very beginning of the load process, after the XML has been loaded, but before Graph construction begins.

If a user constraint is violated, a SarasvatiLoadException should be thrown.

Parameters:
processDefinition - The XmlProcessDefinition to be validated.
Throws:
SarasvatiLoadException

validateExternalDefinition

void validateExternalDefinition(ExternalDefinition externalDefinition)
                                throws SarasvatiLoadException
Allows user validation of each XmlExternal in the XmlProcessDefinition being loaded. This is invoked at the very beginning of the load process, after the XML has been loaded, but before Graph construction begins.

If a user constraint is violated, a SarasvatiLoadException should be thrown.

Parameters:
externalDefinition - The XmlExternal to be validated.
Throws:
SarasvatiLoadException

validateNodeDefinition

void validateNodeDefinition(NodeDefinition nodeDefinition)
                            throws SarasvatiLoadException
Allows user validation of each XmlNode in the XmlProcessDefinition being loaded. This is invoked at the very beginning of the load process, after the XML has been loaded, but before Graph construction begins.

If a user constraint is violated, a SarasvatiLoadException should be thrown.

Parameters:
nodeDefinition - The XmlNode to be validated.
Throws:
SarasvatiLoadException

validateArcDefinition

void validateArcDefinition(ArcDefinition arcDefinition)
                           throws SarasvatiLoadException
Allows user validation of each XmlArc in the XmlProcessDefinition being loaded. This is invoked at the very beginning of the load process, after the XML has been loaded, but before Graph construction begins.

If a user constraint is violated, a SarasvatiLoadException should be thrown.

Parameters:
arcDefinition - The XmlArc to be validated.
Throws:
SarasvatiLoadException

validateExternalArcDefinition

void validateExternalArcDefinition(ExternalArcDefinition externalArcDefinition)
                                   throws SarasvatiLoadException
Allows user validation of each XmlExternalArc in the XmlProcessDefinition being loaded. This is invoked at the very beginning of the load process, after the XML has been loaded, but before Graph construction begins.

If a user constraint is violated, a SarasvatiLoadException should be thrown.

Parameters:
externalArcDefinition - The XmlExternalArc to be validated.
Throws:
SarasvatiLoadException

validateGraph

void validateGraph(Graph graph)
                   throws SarasvatiLoadException
Allows user validation of the loaded Graph, before it is added to the GraphRepository. This is invoked at the very end of the load process, after the XML has been loaded, and after the full Graph has been constructed.

If a user constraint is violated, a SarasvatiLoadException should be thrown.

Parameters:
graph - The Graph to be validated.
Throws:
SarasvatiLoadException

validateNode

void validateNode(Node node)
                  throws SarasvatiLoadException
Allows user validation of each Node in the loaded Graph. This is invoked at the very end of the load process, after the XML has been loaded, and after the full Graph has been constructed.

If a user constraint is violated, a SarasvatiLoadException should be thrown.

Parameters:
node - The Node to be validated.
Throws:
SarasvatiLoadException

validateArc

void validateArc(Arc arc)
                 throws SarasvatiLoadException
Allows user validation of each Arc in the loaded Graph. This is invoked at the very end of the load process, after the XML has been loaded, and after the full Graph has been constructed.

If a user constraint is violated, a SarasvatiLoadException should be thrown.

Parameters:
arc - The Arc to be validated.
Throws:
SarasvatiLoadException