|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.allcolor.yahp.cl.converter.CDocumentCut
public class CDocumentCut
This class handle the {'http://www.allcolor.org/xmlns/yahp','pb'} tag and cut document in multiples documents according to it.
| Nested Class Summary | |
|---|---|
private static class |
CDocumentCut.PbDocument
Represend a part of a document between two pagebreak. |
| Constructor Summary | |
|---|---|
CDocumentCut()
|
|
| Method Summary | |
|---|---|
private static void |
copyHeader(org.w3c.dom.Document doc,
org.w3c.dom.Document ndoc)
Copy the html header from doc to ndoc |
static org.w3c.dom.Document[] |
cut(org.w3c.dom.Document doc)
Cut the given document |
private static CDocumentCut.PbDocument[] |
getPbDocs(org.w3c.dom.NodeList nl)
Return the pagebreaks |
private static boolean |
isDescendant(org.w3c.dom.Node n,
org.w3c.dom.Node ref)
return true if n is a descendant of ref |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public CDocumentCut()
| Method Detail |
|---|
public static org.w3c.dom.Document[] cut(org.w3c.dom.Document doc)
doc - the document to cut
private static boolean isDescendant(org.w3c.dom.Node n,
org.w3c.dom.Node ref)
n - node to testref - reference node
private static CDocumentCut.PbDocument[] getPbDocs(org.w3c.dom.NodeList nl)
nl - pagebreaks nodelist
private static void copyHeader(org.w3c.dom.Document doc,
org.w3c.dom.Document ndoc)
doc - source of html headerndoc - destination
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||