public abstract class BeanPropertySerializer<T,V> extends HasSerializer<V,JsonSerializer<V>>
| Modifier and Type | Field and Description |
|---|---|
protected java.lang.String |
propertyName |
| Modifier | Constructor and Description |
|---|---|
protected |
BeanPropertySerializer(java.lang.String propertyName) |
| Modifier and Type | Method and Description |
|---|---|
protected JsonSerializerParameters |
getParameters() |
java.lang.String |
getPropertyName() |
abstract V |
getValue(T bean,
JsonSerializationContext ctx) |
protected JsonSerializerParameters |
newParameters() |
void |
serialize(JsonWriter writer,
T bean,
JsonSerializationContext ctx)
Serializes the property defined for this instance.
|
void |
serializePropertyName(JsonWriter writer,
T bean,
JsonSerializationContext ctx)
Serializes the property name
|
getSerializer, newSerializerprotected BeanPropertySerializer(java.lang.String propertyName)
protected JsonSerializerParameters getParameters()
protected JsonSerializerParameters newParameters()
public java.lang.String getPropertyName()
public void serializePropertyName(JsonWriter writer, T bean, JsonSerializationContext ctx)
writer - writerbean - bean containing the property to serializectx - context of the serialization processpublic abstract V getValue(T bean, JsonSerializationContext ctx)
bean - bean containing the property to serializectx - context of the serialization processpublic void serialize(JsonWriter writer, T bean, JsonSerializationContext ctx)
writer - writerbean - bean containing the property to serializectx - context of the serialization processCopyright © 2015. All Rights Reserved.