| java.lang.Object org.netbeans.modules.schema2beansdev.TreeBuilder
Method Summary | |
public void | addExtraDataCurLink(Object data) | public void | addExtraDataCurLink(Object[] data) | public void | addExtraDataNode(String uniqueName, String typeName, Object data) | public void | addExtraDataNode(String uniqueName, String typeName, Object[] data) | public void | character(char c) Called each time a character | is found. | public boolean | doesElementExist(String typeName) | public String | dump() | static void | dumpAttributes(GraphNode elt, StringBuffer str, String indent) | static void | dumpTree(List children, StringBuffer str, String indent, boolean tree) | static void | dumpTree(GraphLink l, StringBuffer str, String indent, boolean tree) | public void | element(String uniqueName, String typeName, String attrName, String attrNamespace, int instance, boolean externalType, String defaultValue) Called for each word found in a DTD definition. | public void | element(String uniqueName, String typeName, int instance) | public void | endDocument() Called when the DTD parsing is over.
At this time, the DTD object graph is entirely built. | public void | endElement() | public void | endGroupElements(int instance) We are done creating the elements of a same group,
set the current link to the parent of the group. | public String | getDefaultNamespace() | public GraphNode | getNode(String uniqueName) | public GraphNode[] | getNodes() TreeParser interface. | public PrefixGuesser | getPrefixGuesser() | public GraphNode | getRoot() | static String | instanceToString(int instance, boolean bean) | public void | javaType(String uniqueName, String name, String javaType) Called to request that the graph node named name be of a certain
Java class. | public void | nillable(boolean value) | void | popLevel() | void | pushLevel() | public void | setAbstract(String uniqueName, String name, boolean value) | public void | setDefaultNamespace(String ns) | public void | setExtendedProperty(String uniqueName, String typeName, String propertyName, Object value) | public void | setExtension(String uniqueName, String typeName, String extendsName) | public void | setPrefixGuesser(PrefixGuesser guesser) | public void | setUnion(String uniqueName, String typeName, boolean value) | public void | startDocument(String root) Called once, when the DTD is started to be parsed. | public void | startElement(String uniqueName, String typeName, int type) Called each time a DTD | public void | startGroupElements() Called when a parenthese is found, meaning that the following
elements (element() calls) should be considered as semantically
grouped.
Creates a child GraphLink from the current link to group
all the further elements of this group. | static String | typeToString(int type) |
addExtraDataCurLink | public void addExtraDataCurLink(Object data)(Code) | | |
addExtraDataCurLink | public void addExtraDataCurLink(Object[] data)(Code) | | |
character | public void character(char c)(Code) | | Called each time a character | is found.
|
doesElementExist | public boolean doesElementExist(String typeName)(Code) | | |
element | public void element(String uniqueName, String typeName, String attrName, String attrNamespace, int instance, boolean externalType, String defaultValue)(Code) | | Called for each word found in a DTD definition. This can be a
comment, element or attlist definition. For example, this method is
called for each name element found within the scope of an element
(. The first element name doesn't
generate a call to this method (@see startElement).
This is where the subtree of the element definition is built.
The element to add might be a child or sibling to the previous
element. If the element is preceded by a '(', this is child
(@see startGroupElements), otherwise the element is a sibling.
Parameters: name - the name of the element defined within the declaration. Parameters: instance - has one of the three values: TYPE_0_1,TYPE_1, TYPE_0_N, TYPE_1_N |
endDocument | public void endDocument()(Code) | | Called when the DTD parsing is over.
At this time, the DTD object graph is entirely built. The method
checks the consitency of the built graph, and cleans things up a bit.
|
endElement | public void endElement()(Code) | | Done with an element
|
endGroupElements | public void endGroupElements(int instance)(Code) | | We are done creating the elements of a same group,
set the current link to the parent of the group.
This will allow either to start creating siblings (if element()
is called) or go the next parent level (if this same method
is called again).
|
getDefaultNamespace | public String getDefaultNamespace()(Code) | | |
getNodes | public GraphNode[] getNodes()(Code) | | TreeParser interface. This is what the BeanBuilder uses to get
elements of the tree. The goal is to try to keep separated
the object graph implementation from its usage.
Not sure, this is very useful though, since the tree builder
knows the gory details of the graph. Just a gentle way to ask
for the graph.
|
instanceToString | static String instanceToString(int instance, boolean bean)(Code) | | |
javaType | public void javaType(String uniqueName, String name, String javaType)(Code) | | Called to request that the graph node named name be of a certain
Java class. If the current element type is an attribute, then
we set the javaType of that attribute instead.
Parameters: javaType - is the name of a Java class (eg, "java.lang.Integer", or "int"). |
nillable | public void nillable(boolean value)(Code) | | |
popLevel | void popLevel()(Code) | | |
pushLevel | void pushLevel()(Code) | | |
setDefaultNamespace | public void setDefaultNamespace(String ns)(Code) | | |
startDocument | public void startDocument(String root)(Code) | | Called once, when the DTD is started to be parsed.
Create the GraphNode root element.
Parameters: root - root elemement name of the document (as the DOCTYPEspecifies in the XML document) |
startElement | public void startElement(String uniqueName, String typeName, int type)(Code) | | Called each time a DTD Parameters: name - the name of the element Parameters: typeName - is the name to use for the attribute Parameters: type - the type (as a constant) of the element (for exampleELEMENT or ATTLIST) |
startGroupElements | public void startGroupElements()(Code) | | Called when a parenthese is found, meaning that the following
elements (element() calls) should be considered as semantically
grouped.
Creates a child GraphLink from the current link to group
all the further elements of this group. If any propriety
is defined for this group (as *, ? or + or |) this will be set later
on the current link (as the parent of any of the elements graph link
objects).
|
|
|