anvil.annot
Class AnnotationSpec

java.lang.Object
  |
  +--anvil.annot.AnnotationSpec

public class AnnotationSpec
extends java.lang.Object

Class for storing specification of an annotation like the one stored in litqua.xml -- It contains the group/track hierarchy, attributes and value types


Field Summary
 java.lang.String doc
           
 GuiSpec guiSpec
          Contains defaults for the GUI, set by the user in the specification file.
 GroupSpec specRoot
          The specification is a tree structure on SpecNode objects.
 java.util.Hashtable valueTypes
          This table keeps the user defined value types
 
Constructor Summary
AnnotationSpec()
           
AnnotationSpec(java.io.File file)
           
 
Method Summary
 void addCollapseName(java.lang.String name)
           
 void addValueSetType(java.lang.String name, java.util.List values)
          Adds a new value type with a set of values.
 void createManual(java.io.File dir)
          Creates HTML documentation in directory dir.
 java.util.List findLegalRefTracks(GroupSpec group)
           
 java.util.List findLegalRefTracks(java.lang.String name)
           
 NodeSpec findSpec(java.lang.String path)
          Returns specification object for given path name, e.g.
 java.util.List findTrackNames()
           
 java.util.List getCollapseList()
          Returns list of groups/tracks to be initially collapsed (names).
 java.io.File getFile()
          Returns file name from which this specification was loaded.
 GroupSpec getRoot()
          Returns group spec node that is the root of the annotation spec.
 anvil.annot.meta.SessionDataSpec getSessionDataSpec()
           
 ValueType getValueType(java.lang.String name)
           
 java.util.Hashtable getValueTypes()
          Returns all user-defined value types (class ValueType) in a hashtable.
 void print()
           
 void putValueType(java.lang.String name, ValueType vt)
           
 void removeValueType(java.lang.String name)
           
 void setSessionDataSpec(anvil.annot.meta.SessionDataSpec sds)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

specRoot

public GroupSpec specRoot
The specification is a tree structure on SpecNode objects. The root node is a virtual GroupSpec node with no meaning other than to keep the other nodes together.


guiSpec

public GuiSpec guiSpec
Contains defaults for the GUI, set by the user in the specification file.


valueTypes

public java.util.Hashtable valueTypes
This table keeps the user defined value types


doc

public java.lang.String doc
Constructor Detail

AnnotationSpec

public AnnotationSpec()

AnnotationSpec

public AnnotationSpec(java.io.File file)
Method Detail

getRoot

public GroupSpec getRoot()
Returns group spec node that is the root of the annotation spec.


getValueTypes

public java.util.Hashtable getValueTypes()
Returns all user-defined value types (class ValueType) in a hashtable.


getValueType

public ValueType getValueType(java.lang.String name)

addCollapseName

public void addCollapseName(java.lang.String name)

getCollapseList

public java.util.List getCollapseList()
Returns list of groups/tracks to be initially collapsed (names).


findTrackNames

public java.util.List findTrackNames()

findLegalRefTracks

public java.util.List findLegalRefTracks(java.lang.String name)

findLegalRefTracks

public java.util.List findLegalRefTracks(GroupSpec group)

getFile

public java.io.File getFile()
Returns file name from which this specification was loaded.


findSpec

public NodeSpec findSpec(java.lang.String path)
Returns specification object for given path name, e.g. 'gesture.phrase'.


addValueSetType

public void addValueSetType(java.lang.String name,
                            java.util.List values)
Adds a new value type with a set of values.

Parameters:
values - is a list of ValueSpec elements.

putValueType

public void putValueType(java.lang.String name,
                         ValueType vt)

removeValueType

public void removeValueType(java.lang.String name)

createManual

public void createManual(java.io.File dir)
                  throws java.io.IOException
Creates HTML documentation in directory dir.

Parameters:
dir - directory where to write html files to.
java.io.IOException

print

public void print()

setSessionDataSpec

public void setSessionDataSpec(anvil.annot.meta.SessionDataSpec sds)

getSessionDataSpec

public anvil.annot.meta.SessionDataSpec getSessionDataSpec()