Class MCRPropertiesToJSONTransformer

java.lang.Object
org.mycore.restapi.v1.utils.MCRPropertiesToJSONTransformer
All Implemented Interfaces:
jakarta.ws.rs.ext.MessageBodyWriter<Properties>

@Produces("application/json") @Provider public class MCRPropertiesToJSONTransformer extends Object implements jakarta.ws.rs.ext.MessageBodyWriter<Properties>
  • Constructor Details

    • MCRPropertiesToJSONTransformer

      public MCRPropertiesToJSONTransformer()
  • Method Details

    • isWriteable

      public boolean isWriteable(Class<?> type, Type genericType, Annotation[] annotations, jakarta.ws.rs.core.MediaType mediaType)
      Specified by:
      isWriteable in interface jakarta.ws.rs.ext.MessageBodyWriter<Properties>
    • getSize

      public long getSize(Properties t, Class<?> type, Type genericType, Annotation[] annotations, jakarta.ws.rs.core.MediaType mediaType)
      Specified by:
      getSize in interface jakarta.ws.rs.ext.MessageBodyWriter<Properties>
    • writeTo

      public void writeTo(Properties t, Class<?> type, Type genericType, Annotation[] annotations, jakarta.ws.rs.core.MediaType mediaType, jakarta.ws.rs.core.MultivaluedMap<String,Object> httpHeaders, OutputStream entityStream) throws IOException, jakarta.ws.rs.WebApplicationException
      Specified by:
      writeTo in interface jakarta.ws.rs.ext.MessageBodyWriter<Properties>
      Throws:
      IOException
      jakarta.ws.rs.WebApplicationException