cs.arizona.tau.xml
Class TemporalAnnotationValidator
java.lang.Object
cs.arizona.tau.xml.GenericValidator
cs.arizona.tau.xml.TemporalAnnotationValidator
- All Implemented Interfaces:
- ITemporalAnnotationValidator
public class TemporalAnnotationValidator
- extends GenericValidator
- implements ITemporalAnnotationValidator
- Author:
- spjoshi
TODO :
1) Exception handling.
2) Need to verify whether function createItemPrototypes handles all the conditions.
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
TemporalAnnotationValidator
public TemporalAnnotationValidator(java.lang.String temporalAnnotation,
java.lang.String snapshotSchema,
boolean createItemPrototypes)
TemporalAnnotationValidator
public TemporalAnnotationValidator(org.w3c.dom.Document temporalAnnotationDocument,
org.w3c.dom.Document snapshotSchemaDocument,
TargetIdentifier ti,
boolean createItemPrototypes)
validateTemporalAnnotation
public boolean validateTemporalAnnotation()
- Description copied from interface:
ITemporalAnnotationValidator
- Given snapshot Schema and Temporal Annotations, checks the consistency between them.
The consistency could be checked from various point of views
1) Temporal Annotation should be a valid instance of TXSchema which could be checked using conventional validator.
2) Whether the targets in given Physical Annotation are consistent with given snapshot schema.
- Specified by:
validateTemporalAnnotation
in interface ITemporalAnnotationValidator
getTopTarget
public java.lang.String getTopTarget()
- The function returns the name of topmost element which has been timestamped in Temporal Annotation.
- Returns:
containsTarget
public boolean containsTarget(java.lang.String target)
createItemPrototypes
public void createItemPrototypes()
- The function creates the item prototypes for all the items from temporal annotation.
resetItemCounters
public void resetItemCounters()
getItemPrototype
public Item getItemPrototype(java.lang.String target)
getNextItemID
public java.lang.String getNextItemID(java.lang.String target)
getTargetIterator
public java.util.Iterator getTargetIterator()