Class AbstractWriter

  • All Implemented Interfaces:
    jakarta.ws.rs.ext.MessageBodyWriter<org.eclipse.microprofile.openapi.models.OpenAPI>
    Direct Known Subclasses:
    JsonWriter, YamlWriter

    public abstract class AbstractWriter
    extends Object
    implements jakarta.ws.rs.ext.MessageBodyWriter<org.eclipse.microprofile.openapi.models.OpenAPI>
    • Field Detail

      • mapper

        protected final com.fasterxml.jackson.databind.ObjectMapper mapper
    • Constructor Detail

      • AbstractWriter

        public AbstractWriter​(com.fasterxml.jackson.databind.ObjectMapper mapper)
    • Method Detail

      • 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<org.eclipse.microprofile.openapi.models.OpenAPI>
      • writeTo

        public void writeTo​(org.eclipse.microprofile.openapi.models.OpenAPI 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
        Specified by:
        writeTo in interface jakarta.ws.rs.ext.MessageBodyWriter<org.eclipse.microprofile.openapi.models.OpenAPI>
        Throws:
        IOException