code: protected void writeViewable(Viewable viewable,
                                   MediaType mediaType,
                                   MultivaluedMap<String, Object> httpHeaders,
                                   OutputStream entityStream) throws IOException {
          MessageBodyWriter<Viewable> writer = workers.get().getMessageBodyWriter(Viewable.class, null,
                  new Annotation[]{}, null);
          if (writer != null) {
              writer.writeTo(viewable,
                      Viewable.class,
                      Viewable.class,
                      new Annotation[0],
                      mediaType,
                      httpHeaders,
                      entityStream);
          }
      }
docs: <p>writeViewable.</p>
  
  @param viewable     a {@link org.glassfish.jersey.server.mvc.Viewable} object.
  @param mediaType    a {@link javax.ws.rs.core.MediaType} object.
  @param httpHeaders  a {@link javax.ws.rs.core.MultivaluedMap} object.
  @param entityStream a {@link java.io.OutputStream} object.
  @throws java.io.IOException if any.