Class NamedEntityAdapter<T>
java.lang.Object
javax.xml.bind.annotation.adapters.XmlAdapter<Element,NamedEntity<T>>
com.atlassian.bamboo.rest.adapter.NamedEntityAdapter<T>
- Direct Known Subclasses:
BitbucketNodeEntityAdapter
,FieldErrorsEntityAdapter
public abstract class NamedEntityAdapter<T>
extends javax.xml.bind.annotation.adapters.XmlAdapter<Element,NamedEntity<T>>
Used for creating XML in form of:
which is particularly useful when you're supposed to marshall/unmarshall lists formatted like:
For more explanation see UT for
NamedEntity
class.-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionabstract NamedEntity<T>
createNamedEntity
(@NotNull String name, T value) marshal
(@Nullable NamedEntity<T> entity)
-
Constructor Details
-
NamedEntityAdapter
public NamedEntityAdapter()
-
-
Method Details
-
getEntityType
-
createNamedEntity
-
marshal
- Specified by:
marshal
in classjavax.xml.bind.annotation.adapters.XmlAdapter<Element,
NamedEntity<T>> - Throws:
Exception
-
unmarshal
- Specified by:
unmarshal
in classjavax.xml.bind.annotation.adapters.XmlAdapter<Element,
NamedEntity<T>> - Throws:
Exception
-