Class Dom4jDelegatingElement
java.lang.Object
com.atlassian.plugin.internal.module.Dom4jDelegatingElement
- All Implemented Interfaces:
Element
This class is provided as a migration path and should not be depended upon directly as will not be provided in the
public API as of atlassian plugins 8.0.0.
-
Constructor Summary
ConstructorsConstructorDescriptionDom4jDelegatingElement(org.dom4j.Element dom4jElement) Not for external use, we cannot guarantee the version of dom4j that will be provided. -
Method Summary
Modifier and TypeMethodDescriptionattributeValue(String key) Returns the value for an attribute based on the provided key.attributeValue(String key, String defaultValue) Returns the value for an attribute based on the provided key.Returns the first element which matches the given nameelements()Returns all elements which matches the given nameelementTextTrim(String name) booleanorg.dom4j.ElementgetName()getText()inthashCode()
-
Constructor Details
-
Dom4jDelegatingElement
public Dom4jDelegatingElement(org.dom4j.Element dom4jElement) Not for external use, we cannot guarantee the version of dom4j that will be provided. External Plugin developers should not have a dependency on this Constructor. Using this can lead to unintended breaking changes for external plugin developers.
-
-
Method Details
-
attributeValue
Description copied from interface:ElementReturns the value for an attribute based on the provided key.- Specified by:
attributeValuein interfaceElement- Parameters:
key- that maps to the value to be returned.- Returns:
- the value associated to the provided key.
-
attributeValue
Description copied from interface:ElementReturns the value for an attribute based on the provided key. If the value that would be returned is null, then returns the default value instead.- Specified by:
attributeValuein interfaceElement- Parameters:
key- that maps to the value to be returned.defaultValue- to be returned if the value mapped to the provided key is null.- Returns:
- the attribute mapped to the provided key or the defualtValue provided.
-
element
Description copied from interface:ElementReturns the first element which matches the given name -
elements
Description copied from interface:ElementReturns all elements which matches the given name -
getTextTrim
- Specified by:
getTextTrimin interfaceElement- Returns:
- the text for the current element where whitespace is trimmed and normalised into single spaces. This method does not return null if the text is unknown, but instead an empty String.
-
elementTextTrim
- Specified by:
elementTextTrimin interfaceElement- Parameters:
name- of the element in which the text trim will be provided from.- Returns:
- the text for the element whose name matches the provided name. Where whitespace is trimmed and normalised into single spaces. This method returns null if the text is unknown.
-
getText
-
getName
-
elements
-
attributeNames
- Specified by:
attributeNamesin interfaceElement- Returns:
- all attribute names contained by this element as a list. If no attributes are in the contained element then this will return an empty list.
-
getDelegate
public org.dom4j.Element getDelegate() -
equals
-
hashCode
public int hashCode()
-