Package | Description |
---|---|
org.jdom |
Classes to represent the components of an XML document.
|
org.jdom.input |
Classes to build JDOM documents from various sources.
|
org.jdom.output |
Classes to output JDOM documents to various destinations.
|
org.jdom.transform |
Classes to help with transformations, based on the JAXP TrAX classes.
|
Modifier and Type | Field and Description |
---|---|
protected Element |
Attribute.parent
Parent element, or null if none
|
Modifier and Type | Method and Description |
---|---|
Element |
Element.addContent(Collection newContent)
Appends all children in the given collection to the end of
the content list.
|
Element |
Element.addContent(Content child)
Appends the child to the end of the element's content list.
|
Element |
Element.addContent(int index,
Collection newContent)
Inserts the content in a collection into the content list
at the given index.
|
Element |
Element.addContent(int index,
Content child)
Inserts the child into the content list at the given index.
|
Element |
Element.addContent(String str)
This adds text content to this element.
|
Element |
Document.detachRootElement()
Detach the root
from this document. |
Element |
UncheckedJDOMFactory.element(String name) |
Element |
JDOMFactory.element(String name)
This will create an
Element in no
. |
Element |
DefaultJDOMFactory.element(String name) |
Element |
UncheckedJDOMFactory.element(String name,
Namespace namespace) |
Element |
JDOMFactory.element(String name,
Namespace namespace)
This will create a new
Element
with the supplied (local) name, and define
the to be used. |
Element |
DefaultJDOMFactory.element(String name,
Namespace namespace) |
Element |
UncheckedJDOMFactory.element(String name,
String uri) |
Element |
JDOMFactory.element(String name,
String uri)
This will create a new
Element with
the supplied (local) name, and specifies the URI
of the the Element
should be in, resulting it being unprefixed (in the default
namespace). |
Element |
DefaultJDOMFactory.element(String name,
String uri) |
Element |
UncheckedJDOMFactory.element(String name,
String prefix,
String uri) |
Element |
JDOMFactory.element(String name,
String prefix,
String uri)
This will create a new
Element with
the supplied (local) name, and specifies the prefix and URI
of the the Element
should be in. |
Element |
DefaultJDOMFactory.element(String name,
String prefix,
String uri) |
Element |
Element.getChild(String name)
This returns the first child element within this element with the
given local name and belonging to no namespace.
|
Element |
Element.getChild(String name,
Namespace ns)
This returns the first child element within this element with the
given local name and belonging to the given namespace.
|
Element |
Attribute.getParent()
This will return the parent of this
Attribute . |
Element |
Content.getParentElement()
A convenience method that returns any parent element for this element,
or null if the element is unattached or is a root element.
|
Element |
Document.getRootElement()
This will return the root
Element
for this Document |
Element |
Element.setAttribute(Attribute attribute)
This sets an attribute value for this element.
|
Element |
Element.setAttribute(String name,
String value)
This sets an attribute value for this element.
|
Element |
Element.setAttribute(String name,
String value,
Namespace ns)
This sets an attribute value for this element.
|
Element |
Element.setAttributes(Collection newAttributes)
This sets the attributes of the element.
|
Element |
Element.setAttributes(List newAttributes)
This sets the attributes of the element.
|
Element |
Element.setContent(Collection newContent)
This sets the content of the element.
|
Element |
Element.setContent(Content child)
Set this element's content to be the supplied child.
|
Element |
Element.setContent(int index,
Content child)
Replace the current child the given index with the supplied child.
|
Element |
Element.setName(String name)
Sets the (local) name of the element.
|
Element |
Element.setNamespace(Namespace namespace)
Sets the element's
Namespace . |
Element |
Element.setText(String text)
Sets the content of the element to be the text given.
|
Modifier and Type | Method and Description |
---|---|
void |
UncheckedJDOMFactory.addNamespaceDeclaration(Element parent,
Namespace additional) |
void |
JDOMFactory.addNamespaceDeclaration(Element element,
Namespace additional) |
void |
DefaultJDOMFactory.addNamespaceDeclaration(Element parent,
Namespace additional) |
static String |
Verifier.checkNamespaceCollision(Attribute attribute,
Element element)
|
static String |
Verifier.checkNamespaceCollision(Namespace namespace,
Element element)
|
Document |
UncheckedJDOMFactory.document(Element rootElement) |
Document |
JDOMFactory.document(Element rootElement)
|
Document |
DefaultJDOMFactory.document(Element rootElement) |
Document |
UncheckedJDOMFactory.document(Element rootElement,
DocType docType) |
Document |
JDOMFactory.document(Element rootElement,
DocType docType)
|
Document |
DefaultJDOMFactory.document(Element rootElement,
DocType docType) |
Document |
UncheckedJDOMFactory.document(Element rootElement,
DocType docType,
String baseURI) |
Document |
JDOMFactory.document(Element rootElement,
DocType docType,
String baseURI)
|
Document |
DefaultJDOMFactory.document(Element rootElement,
DocType docType,
String baseURI) |
boolean |
Element.isAncestor(Element element)
Determines if this element is the ancestor of another element.
|
void |
UncheckedJDOMFactory.setAttribute(Element parent,
Attribute a) |
void |
JDOMFactory.setAttribute(Element element,
Attribute a) |
void |
DefaultJDOMFactory.setAttribute(Element parent,
Attribute a) |
protected Attribute |
Attribute.setParent(Element parent)
This will set the parent of this
Attribute . |
Document |
Document.setRootElement(Element rootElement)
This sets the root
for the
Document . |
Constructor and Description |
---|
Document(Element rootElement)
|
Document(Element rootElement,
DocType docType)
|
Document(Element rootElement,
DocType docType,
String baseURI)
|
Modifier and Type | Method and Description |
---|---|
Element |
DOMBuilder.build(Element domElement)
This will build a JDOM Element from an existing DOM Element
|
Element |
SAXHandler.getCurrentElement()
Returns the being-parsed element.
|
Modifier and Type | Method and Description |
---|---|
protected void |
SAXHandler.pushElement(Element element)
Pushes an element onto the tree under construction.
|
Modifier and Type | Method and Description |
---|---|
void |
SAXOutputter.output(Element node)
This will output a single JDOM element as a document, firing
off the SAX events that have been registered.
|
void |
XMLOutputter.output(Element element,
OutputStream out)
|
void |
XMLOutputter.output(Element element,
Writer out)
|
void |
XMLOutputter.outputElementContent(Element element,
OutputStream out)
This will handle printing out an
's content only, not including its tag, and
attributes. |
void |
XMLOutputter.outputElementContent(Element element,
Writer out)
This will handle printing out an
's content only, not including its tag, and
attributes. |
String |
XMLOutputter.outputString(Element element)
Return a string representing an element.
|
protected void |
XMLOutputter.printAttributes(Writer out,
List attributes,
Element parent,
XMLOutputter.NamespaceStack namespaces)
This will handle printing of a
list. |
protected void |
XMLOutputter.printElement(Writer out,
Element element,
int level,
XMLOutputter.NamespaceStack namespaces)
|
Constructor and Description |
---|
JDOMSource(Element source)
Creates a JDOM TrAX source wrapping a JDOM element.
|
Copyright © 2012 JBoss by Red Hat. All Rights Reserved.