|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.util.AbstractCollection java.util.AbstractList java.util.Vector viper.descriptors.DescVector viper.descriptors.DescriptorConfigs
A collection of Descriptor Objects that supports various operations on them, such as comparison between to DescVector, collection of statistics, reading and printing from files, and various others. It extends Vector now, but could be made to extend some sorted list object without too much hassle.
Field Summary |
Fields inherited from class java.util.Vector |
capacityIncrement, elementCount, elementData |
Fields inherited from class java.util.AbstractList |
modCount |
Constructor Summary | |
DescriptorConfigs(DescriptorData parent)
Constructs an empty set of DescriptorConfigs. |
Method Summary | |
boolean |
addDesConfig(org.w3c.dom.Element configEl)
Adds the descriptor prototype described by the given XML DOM node. |
boolean |
addDesConfig(org.xml.sax.InputSource input)
Adds the descriptor schema from the given xml input source. |
boolean |
addDesConfig(VReader reader)
Reads in Descriptor configuration information from the specified VReader. |
Descriptor |
addFromGtf(org.w3c.dom.Element curr,
DescVector relativeVector)
Parses the given descriptor instance element. |
Descriptor |
addFromGtf(VReader reader,
DescVector relativeVector)
Reads in the next Descriptor from a VReader. |
org.w3c.dom.Element |
getXMLFormat(org.w3c.dom.Document root)
Returns a config tag with lots of children. |
void |
parseConfig(java.util.Vector allFiles)
Reads in a set of Desxcriptor configuration information to this DescVector. |
void |
parseConfig(java.util.Vector allFiles,
boolean all,
boolean err,
boolean warn,
boolean bad,
boolean totals)
Reads in a set of Desxcriptor configuration information to this DescVector. |
void |
printConfig(java.io.PrintWriter output)
Prints out all Descriptor objects in the list. |
void |
printOut(java.io.PrintWriter output)
Prints the data out to a file in the specified format. |
java.lang.String |
toString()
Prints the descriptors in .gtf style. |
Methods inherited from class viper.descriptors.DescVector |
addDescriptor, cropNodesToSpan, getAllDescriptors, getFileInformation, getHighestFrame, getIds, getInformation, getLowestFrame, getMap, getNodeByID, getNodesByFrame, getNodesByID, getNodesByType, getNodesByType, getParent, getSourcefileName, hasDescriptor, parseData, parseData, parseData, parseData, setFileInformation, setMap, setSourcefileName |
Methods inherited from class java.util.Vector |
add, add, addAll, addAll, addElement, capacity, clear, clone, contains, containsAll, copyInto, elementAt, elements, ensureCapacity, equals, firstElement, get, hashCode, indexOf, indexOf, insertElementAt, isEmpty, lastElement, lastIndexOf, lastIndexOf, remove, remove, removeAll, removeAllElements, removeElement, removeElementAt, removeRange, retainAll, set, setElementAt, setSize, size, subList, toArray, toArray, trimToSize |
Methods inherited from class java.util.AbstractList |
iterator, listIterator, listIterator |
Methods inherited from class java.lang.Object |
finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface viper.descriptors.DescriptorList |
clone, get, size |
Methods inherited from interface java.util.Collection |
add, addAll, clear, contains, containsAll, equals, hashCode, isEmpty, iterator, remove, removeAll, retainAll, toArray, toArray |
Methods inherited from interface java.util.List |
iterator, listIterator, listIterator |
Constructor Detail |
public DescriptorConfigs(DescriptorData parent)
parent
- the parent dataMethod Detail |
public void parseConfig(java.util.Vector allFiles)
allFiles
- a Vector of Strings containing the names
of the files to search for config informationpublic void parseConfig(java.util.Vector allFiles, boolean all, boolean err, boolean warn, boolean bad, boolean totals)
allFiles
- a Vector of Strings containing the names
of the files to search for config informationall
- print out all lineserr
- print out error messageswarn
- print out warning messagesbad
- print out general errorstotals
- print out error totalspublic boolean addDesConfig(VReader reader)
reader
- - the VReader containing the config info
public boolean addDesConfig(org.w3c.dom.Element configEl)
configEl
- the dom node (a config node)
public boolean addDesConfig(org.xml.sax.InputSource input) throws BadDataException, java.io.IOException
input
- the input source
BadDataException
java.io.IOException
public Descriptor addFromGtf(VReader reader, DescVector relativeVector) throws BadDataException, EndOfBlockException, ImproperDescriptorException
reader
- where to get the Descriptor fromrelativeVector
- constructs them using this
BadDataException
- if the data is in an incorrect format.
EndOfBlockException
- if there is a data block overrun in the VReader
ImproperDescriptorException
- if there is no such data found in the DescriptorConfigspublic Descriptor addFromGtf(org.w3c.dom.Element curr, DescVector relativeVector) throws BadDataException, ImproperDescriptorException
curr
- the descriptor instancerelativeVector
- the parent list
BadDataException
ImproperDescriptorException
public void printConfig(java.io.PrintWriter output)
output
- where to print the informationpublic void printOut(java.io.PrintWriter output)
printOut
in class DescVector
output
- - the PrintWriter to hand the datapublic java.lang.String toString()
toString
in class DescVector
public org.w3c.dom.Element getXMLFormat(org.w3c.dom.Document root)
getXMLFormat
in interface DescriptorList
getXMLFormat
in class DescVector
root
- The DOM root
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |