public class ElementTreeBuilder extends Object
Please note we used d-tree code as a basis for our. d-tree was not our original work. Nothing on the original copyright notice stated that we can't use it the way we do. We contacted the author about that but had no answer so far. Therefore, we conclude that we can use his code (and the JavaScript library as well). If some disagree, we'll be able to explain and, if needed, comply...
This class traverses a tree defined as follows:
Constructor and Description |
---|
ElementTreeBuilder(PrintWriter out,
DTDCommenter commenter,
Set dtds,
Logger log) |
Modifier and Type | Method and Description |
---|---|
static void |
generateJavascriptSetup(PrintWriter out)
Generates preliminary Javascript code needed to load the d-tree library.
|
void |
generateTree()
Builds the HTML/Javascript code necessary to the invocation of d-tree.
|
void |
visitContainer(int parentId,
com.wutka.dtd.DTDContainer container)
Visit a container and generate the Javascript d-tree code.
|
public ElementTreeBuilder(PrintWriter out, DTDCommenter commenter, Set dtds, Logger log)
public void generateTree()
public void visitContainer(int parentId, com.wutka.dtd.DTDContainer container)
parentId
- The parent id of the parent of the container (-1 if none).container
- The container to visit.Exception
- If anything goes wrong.public static void generateJavascriptSetup(PrintWriter out)
out
- Where to generate the code.Copyright © 2002-2012 DTDDoc. All Rights Reserved.