org.zkoss.idom.input
Interface IDOMFactory

All Known Implementing Classes:
DefaultIDOMFactory

public interface IDOMFactory

A DOM factory. It is the interface used by SaxBuild to create corresponding vertices. By implementing this interface or overriding DefaultDomFactory, caller could create a set of vertices other than the default ones.

Author:
tomyeh
See Also:
SAXBuilder

Method Summary
 Attribute newAttribute(Namespace ns, java.lang.String lname, java.lang.String value)
          Creates an Attribute with namespace.
 Attribute newAttribute(java.lang.String lname, java.lang.String value)
          Creates an Attribute without namespace.
 CData newCData(java.lang.String text)
          Creates a CData.
 Comment newComment(java.lang.String text)
          Creates a Comment.
 DocType newDocType(java.lang.String elementName, java.lang.String publicId, java.lang.String systemId)
          Creates a DocType.
 Document newDocument(Element rootElement, DocType docType)
          Creates a Document.
 Element newElement(Namespace ns, java.lang.String lname)
          Creates an Element with a namespace.
 Element newElement(java.lang.String lname)
          Creates an Element without namespace.
 EntityReference newEntityRef(java.lang.String name)
          Creates an EntityReference.
 ProcessingInstruction newProcessingInstruction(java.lang.String target, java.lang.String data)
          Creates a processing instruction.
 Text newText(java.lang.String text)
          Creates a Text.
 

Method Detail

newAttribute

Attribute newAttribute(java.lang.String lname,
                       java.lang.String value)
Creates an Attribute without namespace.


newAttribute

Attribute newAttribute(Namespace ns,
                       java.lang.String lname,
                       java.lang.String value)
Creates an Attribute with namespace.


newCData

CData newCData(java.lang.String text)
Creates a CData.


newComment

Comment newComment(java.lang.String text)
Creates a Comment.


newDocType

DocType newDocType(java.lang.String elementName,
                   java.lang.String publicId,
                   java.lang.String systemId)
Creates a DocType.

Parameters:
elementName - the root element's name
publicId - the public Id; null for empty
systemId - the system Id; null for empty

newDocument

Document newDocument(Element rootElement,
                     DocType docType)
Creates a Document.

Parameters:
docType - the document type; null for not available

newElement

Element newElement(Namespace ns,
                   java.lang.String lname)
Creates an Element with a namespace.


newElement

Element newElement(java.lang.String lname)
Creates an Element without namespace.


newProcessingInstruction

ProcessingInstruction newProcessingInstruction(java.lang.String target,
                                               java.lang.String data)
Creates a processing instruction.

Parameters:
data - the raw data; null for empty

newEntityRef

EntityReference newEntityRef(java.lang.String name)
Creates an EntityReference.

Parameters:
name - the entity reference's name

newText

Text newText(java.lang.String text)
Creates a Text.



Copyright © 2005-2011 Potix Corporation. All Rights Reserved. SourceForge.net Logo