com.liberologico.cloudesire.cmw.model.serializer.PriceSerializer Maven / Gradle / Ivy
The newest version!
package com.liberologico.cloudesire.cmw.model.serializer;
import com.fasterxml.jackson.core.JsonGenerator;
import com.fasterxml.jackson.databind.JsonSerializer;
import com.fasterxml.jackson.databind.SerializerProvider;
import java.io.IOException;
import java.math.BigDecimal;
public class PriceSerializer extends JsonSerializer
{
@Override
public void serialize( BigDecimal value, JsonGenerator jgen, SerializerProvider provider ) throws IOException
{
jgen.writeString( value.toPlainString() );
}
}