Class EntryWriter

java.lang.Object
com.tangosol.coherence.rest.providers.EntryWriter
All Implemented Interfaces:
javax.ws.rs.ext.MessageBodyWriter<Object>

@Provider @Produces({"application/xml","application/json"}) public class EntryWriter extends Object implements javax.ws.rs.ext.MessageBodyWriter<Object>
Provider responsible for marshalling map entries.
Author:
as 2015.07.22
  • Constructor Details

    • EntryWriter

      public EntryWriter()
      Default constructor.
    • EntryWriter

      public EntryWriter(MarshallerRegistry registry)
      Construct an EntryWriter instance.
      Parameters:
      registry - marshaller registry to use
  • Method Details

    • isWriteable

      public boolean isWriteable(Class<?> clz, Type type, Annotation[] aAnnotation, javax.ws.rs.core.MediaType mediaType)
      Specified by:
      isWriteable in interface javax.ws.rs.ext.MessageBodyWriter<Object>
    • getSize

      public long getSize(Object entry, Class<?> clz, Type type, Annotation[] aAnnotation, javax.ws.rs.core.MediaType mediaType)
      Specified by:
      getSize in interface javax.ws.rs.ext.MessageBodyWriter<Object>
    • writeTo

      public void writeTo(Object oEntry, Class<?> clz, Type type, Annotation[] aAnnotation, javax.ws.rs.core.MediaType mediaType, javax.ws.rs.core.MultivaluedMap<String,Object> httpHeaders, OutputStream stream) throws IOException, javax.ws.rs.WebApplicationException
      Specified by:
      writeTo in interface javax.ws.rs.ext.MessageBodyWriter<Object>
      Throws:
      IOException
      javax.ws.rs.WebApplicationException