Class GsonObjectSerialDeserial

  • All Implemented Interfaces:
    org.wicketstuff.rest.contenthandling.IObjectSerialDeserial<String>

    public class GsonObjectSerialDeserial
    extends Object
    implements org.wicketstuff.rest.contenthandling.IObjectSerialDeserial<String>
    Object serializer/deserailizer that works with JSON format and based on Gson library.
    Author:
    andrea del bene
    • Constructor Detail

      • GsonObjectSerialDeserial

        public GsonObjectSerialDeserial​(com.google.gson.Gson gson)
      • GsonObjectSerialDeserial

        public GsonObjectSerialDeserial()
    • Method Detail

      • serializeObject

        public String serializeObject​(Object target,
                                      String mimeType)
        Specified by:
        serializeObject in interface org.wicketstuff.rest.contenthandling.IObjectSerialDeserial<String>
      • deserializeObject

        public <E> E deserializeObject​(String source,
                                       Class<E> targetClass,
                                       String mimeType)
        Specified by:
        deserializeObject in interface org.wicketstuff.rest.contenthandling.IObjectSerialDeserial<String>
      • getGson

        public com.google.gson.Gson getGson()