|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object | +--xmltool.datastructure.PData
All parsing (using IBM Alphaworks parser) and mapping a DTD to a ParsedData structure is done by this class.
| Field Summary | |
ParsedData |
root
Root ParsedData of the DTD |
java.lang.String[] |
valAll
Validation array, to check if all the elements have been considered |
boolean |
valid
Flag to denote if the filename for the DTD entered is valid |
java.util.Vector |
vect
Vector which contains the child elements |
int |
vectCount
Total number of DTD elements having child elements |
| Constructor Summary | |
PData()
Default constructor |
|
| Method Summary | |
com.ibm.xml.parser.DTD |
getDTD()
|
boolean |
inArray(java.lang.String string)
Returns if the element or attribute has been considered or not |
ParsedData |
isParsed(java.lang.String string)
Returns the reference of the ParsedData if it occurs more than once in the dTD, so that we dont have infinite looping. |
ParsedData |
parseIt(java.lang.String mystring)
Parser |
void |
putIntoArray(java.lang.String string)
Puts into ValAll, all the elements and attributes |
ParsedData |
recursiveIsParsed(ParsedData pd,
java.lang.String string)
This is doing the recursive job of traversing thro the data structures and returns the answer needed by isParsed |
void |
Validate(java.util.Vector vects,
ParsedData parent,
int count)
Validates the elements and its children and makes the complex ParsedData structure |
| Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
| Field Detail |
public ParsedData root
public boolean valid
public int vectCount
public java.util.Vector vect
public java.lang.String[] valAll
| Constructor Detail |
public PData()
| Method Detail |
public com.ibm.xml.parser.DTD getDTD()
public ParsedData parseIt(java.lang.String mystring)
string - The filename of the DTD to be parsed
return ParsedData The root ParsedData of the DTD to be parsedpublic ParsedData isParsed(java.lang.String string)
public ParsedData recursiveIsParsed(ParsedData pd,
java.lang.String string)
public boolean inArray(java.lang.String string)
string - the element or attribute to be checked
return boolean true if the element is present in the array, else falsepublic void putIntoArray(java.lang.String string)
string - the element or attribute to be entered
public void Validate(java.util.Vector vects,
ParsedData parent,
int count)
vects - Vector containing children of the current elementparent - Parent ParsedData of this vectscount - Element[count] in the ParsedData of the parent whose child is "parent.elemsPD[count]"
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||