Modifier and Type | Class and Description |
---|---|
private class |
Element.DataOnly |
private class |
Element.HasOneRef
For things like "element foo {refToAnotherPattern}"
|
(package private) static interface |
Element.Strategy |
private class |
Element.ToInterface
Maps to an interface
|
Modifier and Type | Field and Description |
---|---|
boolean |
isRoot
True if this element can be a root element.
|
private Element.Strategy |
strategy |
alternativeName
Constructor and Description |
---|
Element(org.xml.sax.Locator location,
javax.xml.namespace.QName name,
Leaf leaf) |
Modifier and Type | Method and Description |
---|---|
private Element.Strategy |
decideStrategy()
Returns true if this element should generate an interface.
|
(package private) void |
declare(NodeSet nset)
Declares the class without its contents.
|
(package private) void |
generate(com.sun.codemodel.JDefinedClass clazz,
NodeSet nset,
java.util.Set<Prop> props)
Populate the body of the writer class.
|
(package private) void |
generate(NodeSet nset)
Generates the contents.
|
private com.sun.codemodel.JMethod |
generateMethod(com.sun.codemodel.JDefinedClass clazz,
NodeSet nset,
com.sun.codemodel.JType retT) |
java.lang.String |
toString() |
collectChildren
prepare
addChild, hasOneChild, iterator
createDataMethod, getNext, getPrev, merge, siblings
public boolean isRoot
private Element.Strategy strategy
public Element(org.xml.sax.Locator location, javax.xml.namespace.QName name, Leaf leaf)
private Element.Strategy decideStrategy()
void declare(NodeSet nset)
WriterNode
declare
in class WriterNode
void generate(NodeSet nset)
WriterNode
generate
in class WriterNode
void generate(com.sun.codemodel.JDefinedClass clazz, NodeSet nset, java.util.Set<Prop> props)
Leaf
private com.sun.codemodel.JMethod generateMethod(com.sun.codemodel.JDefinedClass clazz, NodeSet nset, com.sun.codemodel.JType retT)
public java.lang.String toString()
toString
in class java.lang.Object