net.jxta.document
Interface StructuredDocument
- All Superinterfaces:
- Document, Element
- All Known Subinterfaces:
- StructuredTextDocument, XMLDocument
public interface StructuredDocument
- extends Document, Element
An extension of Document
which allows the content of a document to be
specified by a hierarchy of elements. This allows the content of many
document types to be mainpulated in an abstract way without regard to the
phyiscal representation of the documents.
StructuredDocuments are one of the elementary components that is
manipulated by the JXTA core. StructuredDocuments are used to represent most
core objects such as peer, peergroup or pipe advertisements.
- See Also:
Document
,
StructuredTextDocument
,
StructuredDocumentFactory
createElement
Element createElement(Object key)
- Create a new element without value
- Parameters:
key
- The key of the element to be created.
- Returns:
- The new element.
createElement
Element createElement(Object key,
Object value)
- Create a new element with value
- Parameters:
key
- The name of the element to be created.value
- The value of the element to be created or
null
if no value is desired.
- Returns:
- The new element.