|
Enhydra 3.0.3 API | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Interface for a factory class that can create DocumentType and Document objects. It also provides document-type specific functions.
Classes implementing this must:
Method Summary | |
Document |
createDocument(java.lang.String qualifiedName,
DocumentType doctype)
Creates an XML Document object of the specified type with
its document element. |
DocumentType |
createDocumentType(java.lang.String qualifiedName,
java.lang.String publicID,
java.lang.String systemID,
java.lang.String internalSubset)
Creates an empty DocumentType node. |
java.lang.String |
getBaseClassName()
Get the base class name for generated classes. |
java.lang.String |
getBaseInterfaceName()
Get the base interface name for generated interfaces. |
java.lang.String[] |
getElementClassNames(Element element)
Extract the class names for an element. |
java.lang.String[] |
getElementURLAttrs(Element element)
Get a list of attribute names for an element who's value can be a URL. |
boolean |
needsCreateTextSetMethod(Element element)
Determine if this element should have an set method created for it's first text child. |
java.lang.String |
nodeClassToInterface(Node node)
Convert an implementation-specific DOM node class name to the external interface or class name that should be used to reference it. |
void |
setErrorChecking(Document doc,
boolean check)
Enable or disable optional DOM error checking. |
Method Detail |
public DocumentType createDocumentType(java.lang.String qualifiedName, java.lang.String publicID, java.lang.String systemID, java.lang.String internalSubset)
DocumentType
node.qualifiedName
- The document type name (same as the root element).publicID
- The document type public identifier.systemID
- The document type system identifier.internalSubset
- The internal subset as a string.DocumentType
node with
Node.ownerDocument
set to null
.
For HTML DOM factories, this returns null.public Document createDocument(java.lang.String qualifiedName, DocumentType doctype)
Document
object of the specified type with
its document element.qualifiedName
- The document type name (same as the root element).
Maybe null for HTML documents.doctype
- The type of document to be created or null
.
When doctype
is not null
, its
Node.ownerDocument
attribute is set to the document being
created. Maybe null for for documents without DTDs or HTML documents.Document
object.public void setErrorChecking(Document doc, boolean check)
Note: as a short-term performance enhancement, this also enables/disables DOM level 2 mutation events. Don't count on this functionality in future releases.
doc
- the document to operate on.check
- true to enable error checking, false to disable it.public java.lang.String getBaseClassName()
public java.lang.String getBaseInterfaceName()
public java.lang.String nodeClassToInterface(Node node)
org.w3c.dom
interface or
other interface or class.public java.lang.String[] getElementClassNames(Element element)
class
attribute and with a value of a white-space
separated list of class names. Its not specified for XML, however this
method can be implemented in DTD-specifc XMLDomFactories to enable this
functionality.public java.lang.String[] getElementURLAttrs(Element element)
public boolean needsCreateTextSetMethod(Element element)
|
Enhydra 3.0.3 API | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |