Uses of Class
org.jdom2.Namespace
Packages that use Namespace
Package
Description
Classes representing the components of an XML document.
Classes to both filter and generically type-cast nodes of a document
based on type, name, value, or other aspects, and to boolean
AND/OR/NEGATE these rules.
Support classes for building JDOM documents and content using StAX readers.
Extended JDOM Content Classes that contain location coordinates.
Classes used to implement output functionality that are not part of the
actual Output API, but rather part of the implementation.
Classes that implement useful functionality, but are not easy to categorise.
-
Uses of Namespace in org.jdom2
Modifier and TypeFieldDescriptionprotected Namespace
Attribute.namespace
The
of theNamespace
Attribute
protected Namespace
Element.namespace
The namespace of the elementstatic final Namespace
Namespace.NO_NAMESPACE
Define aNamespace
for when not in a namespacestatic final Namespace
Namespace.XML_NAMESPACE
Define aNamespace
for the standard xml prefix.Modifier and TypeMethodDescriptionAttribute.getNamespace()
This will return thisAttribute
's
.Namespace
Element.getNamespace()
Returns the element'sNamespace
.Element.getNamespace
(String prefix) Returns theNamespace
corresponding to the given prefix in scope for this element.static Namespace
Namespace.getNamespace
(String uri) This will retrieve (if in existence) or create (if not) aNamespace
for the supplied URI, and make it usable as a default namespace, as no prefix is supplied.static Namespace
Namespace.getNamespace
(String prefix, String uri) This will retrieve (if in existence) or create (if not) aNamespace
for the supplied prefix and uri.Modifier and TypeMethodDescriptionElement.getAdditionalNamespaces()
Returns a list of the additional namespace declarations on this element.Attribute.getNamespacesInherited()
Content.getNamespacesInherited()
Document.getNamespacesInherited()
Element.getNamespacesInherited()
NamespaceAware.getNamespacesInherited()
Obtain a list of all namespaces that are in scope for this content, but were not introduced by this content.Attribute.getNamespacesInScope()
Get the namespaces that are in-scope on this Attribute.Content.getNamespacesInScope()
Document.getNamespacesInScope()
Get the Namespaces that are in-scope on this Document.Element.getNamespacesInScope()
Get the Namespaces that are in-scope on this Element.NamespaceAware.getNamespacesInScope()
Obtain a list of all namespaces that are in scope for the current content.Attribute.getNamespacesIntroduced()
Content.getNamespacesIntroduced()
Document.getNamespacesIntroduced()
Element.getNamespacesIntroduced()
NamespaceAware.getNamespacesIntroduced()
Obtain a list of all namespaces that are introduced to the XML tree by this node.Modifier and TypeMethodDescriptionvoid
DefaultJDOMFactory.addNamespaceDeclaration
(Element parent, Namespace additional) boolean
Element.addNamespaceDeclaration
(Namespace additionalNamespace) Adds a namespace declarations to this element.void
JDOMFactory.addNamespaceDeclaration
(Element element, Namespace additional) Adds a namespace declaration to an Elementvoid
UncheckedJDOMFactory.addNamespaceDeclaration
(Element parent, Namespace additional) Deprecated.DefaultJDOMFactory.attribute
(String name, String value, AttributeType type, Namespace namespace) Deprecated.JDOMFactory.attribute
(String name, String value, AttributeType type, Namespace namespace) This will create a newAttribute
with the specified (local) name, value, and type, and in the provided
.Namespace
This will create a newAttribute
with the specified (local) name and value, and in the provided
.Namespace
Deprecated.SlimJDOMFactory.attribute
(String name, String value, AttributeType type, Namespace namespace) Deprecated.UncheckedJDOMFactory.attribute
(String name, String value, AttributeType type, Namespace namespace) static String
Verifier.checkNamespaceCollision
(Namespace namespace, List<?> list) Check if a
collides with any namespace from a list of objects.Namespace
static String
Verifier.checkNamespaceCollision
(Namespace namespace, List<?> list, int ignoreatt) Check if a
collides with any namespace from a list of objects.Namespace
static String
Verifier.checkNamespaceCollision
(Namespace namespace, Attribute attribute) static String
Verifier.checkNamespaceCollision
(Namespace namespace, Element element) static String
Verifier.checkNamespaceCollision
(Namespace namespace, Element element, int ignoreatt) static String
Verifier.checkNamespaceCollision
(Namespace namespace, Namespace other) Check if two namespaces collide.final Element
This will create a newElement
with the supplied (local) name, and define the
to be used.Namespace
This will create a newElement
with the supplied (local) name, and define the
to be used.Namespace
Element.getAttribute
(String attname, Namespace ns) This returns the attribute for this element with the given name and within the given Namespace, or null if no such attribute exists.Element.getAttributeValue
(String attname, Namespace ns) This returns the attribute value for the attribute with the given name and within the given Namespace, null if there is no such attribute, and the empty string if the attribute value is empty.Element.getAttributeValue
(String attname, Namespace ns, String def) This returns the attribute value for the attribute with the given name and within the given Namespace, or the passed-in default if there is no such attribute.This returns the first child element within this element with the given local name and belonging to the given namespace.Element.getChildren
(String cname, Namespace ns) This returns aList
of all the child elements nested directly (one level deep) within this element with the given local name and belonging to the given Namespace, returned asElement
objects.Element.getChildText
(String cname, Namespace ns) Returns the textual content of the named child element, or null if there's no such child.Element.getChildTextNormalize
(String cname, Namespace ns) Returns the normalized textual content of the named child element, or null if there's no such child.Element.getChildTextTrim
(String cname, Namespace ns) Returns the trimmed textual content of the named child element, or null if there's no such child.boolean
Element.removeAttribute
(String attname, Namespace ns) This removes the attribute with the given name and within the given Namespace.boolean
Element.removeChild
(String cname, Namespace ns) This removes the first child element (one level deep) with the given local name and belonging to the given namespace.boolean
Element.removeChildren
(String cname, Namespace ns) This removes all child elements (one level deep) with the given local name and belonging to the given namespace.void
Element.removeNamespaceDeclaration
(Namespace additionalNamespace) Removes an additional namespace declarations from this element.Element.setAttribute
(String name, String value, Namespace ns) This sets an attribute value for this element.Attribute.setNamespace
(Namespace namespace) This sets thisAttribute
's
.Namespace
Element.setNamespace
(Namespace namespace) Sets the element'sNamespace
.ModifierConstructorDescriptionDeprecated.Attribute
(String name, String value, AttributeType type, Namespace namespace) This will create a newAttribute
with the specified (local) name, value, and type, and in the provided
.Namespace
This will create a newAttribute
with the specified (local) name and value, and in the provided
.Namespace
Creates a new element with the supplied (local) name and namespace. -
Uses of Namespace in org.jdom2.filter
Methods in org.jdom2.filter with parameters of type NamespaceModifier and TypeMethodDescriptionReturn a Filter that matches anyAttribute
data with the specified name and namespace.Return a Filter that matches anyAttribute
data with the specified namespace.Return a Filter that matches anyElement
data with the specified name and Namespace.Return a Filter that matches anyElement
data with the specified Namespace.Constructors in org.jdom2.filter with parameters of type NamespaceModifierConstructorDescriptionAttributeFilter
(String name, Namespace namespace) Select only the Attributes with the supplied name and Namespace.AttributeFilter
(Namespace namespace) Select only the Attributes with the supplied Namespace.ElementFilter
(String name, Namespace namespace) Select only the Elements with the supplied name and Namespace.ElementFilter
(Namespace namespace) Select only the Elements with the supplied Namespace. -
Uses of Namespace in org.jdom2.input.stax
Methods in org.jdom2.input.stax with parameters of type NamespaceModifier and TypeMethodDescriptionboolean
DefaultStAXFilter.includeElement
(int depth, String name, Namespace ns) boolean
StAXFilter.includeElement
(int depth, String name, Namespace ns) The current event is an Element event.boolean
DefaultStAXFilter.pruneElement
(int depth, String name, Namespace ns) boolean
StAXFilter.pruneElement
(int depth, String name, Namespace ns) An Element is being included, and this is a child Element event of the included parent Element. -
Uses of Namespace in org.jdom2.located
Methods in org.jdom2.located with parameters of type NamespaceModifier and TypeMethodDescriptionConstructors in org.jdom2.located with parameters of type NamespaceModifierConstructorDescriptionLocatedElement
(String name, Namespace namespace) Creates a new element with the supplied (local) name and namespace. -
Uses of Namespace in org.jdom2.output.support
Methods in org.jdom2.output.support with parameters of type NamespaceModifier and TypeMethodDescriptionprotected void
AbstractStAXStreamProcessor.printNamespace
(XMLStreamWriter out, FormatStack fstack, Namespace ns) This will handle printing of any needed
declarations.Namespace
protected void
AbstractXMLOutputProcessor.printNamespace
(Writer out, FormatStack fstack, Namespace ns) This will handle printing of any needed
declarations.Namespace
-
Uses of Namespace in org.jdom2.util
Methods in org.jdom2.util that return NamespaceModifier and TypeMethodDescriptionNamespaceStack.getAllNamespacesForURI
(String uri) Get all prefixes in the current scope that are bound to the specified URI.NamespaceStack.getFirstNamespaceForURI
(String uri) Get the first Namespace in the current scope that is bound to the specified URI.NamespaceStack.getNamespaceForPrefix
(String prefix) Get the Namespace in the current scope with the specified prefix.NamespaceStack.getRebound
(String prefix) If the specified prefix was bound in the previous bind level, and has been rebound to a different URI in the current level, then return the Namespace the the prefix was bound to before.NamespaceStack.getScope()
Return a new array instance representing the current scope.Methods in org.jdom2.util that return types with arguments of type NamespaceModifier and TypeMethodDescriptionNamespaceStack.addedForward()
Return an Iterable containing all the Namespaces introduced to the current-level's scope.NamespaceStack.addedReverse()
Return an Iterable containing all the Namespaces introduced to the current-level's scope but in reverse order toNamespaceStack.addedForward()
.NamespaceStack.iterator()
Get all the Namespaces in-scope at the current level of the stack.Methods in org.jdom2.util with parameters of type NamespaceModifier and TypeMethodDescriptionboolean
Inspect the current scope and return true if the specified namespace is in scope.void
Create a new in-scope level for the Stack based on an arbitrary set of Namespaces.Method parameters in org.jdom2.util with type arguments of type NamespaceModifier and TypeMethodDescriptionvoid
Create a new in-scope level for the Stack based on an arbitrary set of Namespaces.Constructors in org.jdom2.util with parameters of type NamespaceModifierConstructorDescriptionJDOMNamespaceContext
(Namespace[] namespaces) Create a read-only representation of the input namespace list.NamespaceStack
(Namespace[] seed) Create a NamespaceWalker ready to use as a stack.
JDOMFactory.attribute(String, String, AttributeType, Namespace)