public class QNameTransformer extends java.lang.Object implements AttributeTransformer, FieldTransformer
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
QNAME_NAMESPACE_PREFIX |
Constructor and Description |
---|
QNameTransformer(java.lang.String xPath) |
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
buildAttributeValue(Record record,
java.lang.Object object,
Session session) |
java.lang.Object |
buildFieldValue(java.lang.Object instance,
java.lang.String fieldName,
Session session) |
void |
initialize(AbstractTransformationMapping mapping)
Initialize this transformer.
|
public static final java.lang.String QNAME_NAMESPACE_PREFIX
public void initialize(AbstractTransformationMapping mapping)
FieldTransformer
initialize
in interface AttributeTransformer
initialize
in interface FieldTransformer
mapping
- - The mapping associated with this transformer. Only used if some special information is required.public java.lang.Object buildAttributeValue(Record record, java.lang.Object object, Session session)
buildAttributeValue
in interface AttributeTransformer
record
- - The metadata being used to build the object.object
- - The current object that the attribute is being built for.session
- - the current sessionpublic java.lang.Object buildFieldValue(java.lang.Object instance, java.lang.String fieldName, Session session)
buildFieldValue
in interface FieldTransformer
instance
- - an instance of the domain class which contains the attributefieldName
- - the name of the field being transformed. Used if the user wants to use this transformer for multiple fields.session
- - the current session