@Produces(value={"application/xml","text/xml","*/*"}) @Consumes(value={"application/xml","text/xml","*/*"}) @Singleton public static final class SourceProvider.SourceWriter extends Object implements MessageBodyWriter<Source>
Source instances.| Constructor and Description |
|---|
SourceWriter(javax.inject.Provider<SAXParserFactory> spf,
javax.inject.Provider<TransformerFactory> tf) |
| Modifier and Type | Method and Description |
|---|---|
long |
getSize(Source o,
Class<?> type,
Type genericType,
Annotation[] annotations,
MediaType mediaType) |
boolean |
isWriteable(Class<?> t,
Type gt,
Annotation[] as,
MediaType mediaType) |
void |
writeTo(Source source,
Class<?> t,
Type gt,
Annotation[] as,
MediaType mediaType,
MultivaluedMap<String,Object> httpHeaders,
OutputStream entityStream) |
@Inject public SourceWriter(@Context javax.inject.Provider<SAXParserFactory> spf, @Context javax.inject.Provider<TransformerFactory> tf)
public boolean isWriteable(Class<?> t, Type gt, Annotation[] as, MediaType mediaType)
isWriteable in interface MessageBodyWriter<Source>public long getSize(Source o, Class<?> type, Type genericType, Annotation[] annotations, MediaType mediaType)
getSize in interface MessageBodyWriter<Source>public void writeTo(Source source, Class<?> t, Type gt, Annotation[] as, MediaType mediaType, MultivaluedMap<String,Object> httpHeaders, OutputStream entityStream) throws IOException
writeTo in interface MessageBodyWriter<Source>IOExceptionCopyright © 2007-2023, Oracle and/or its affiliates. All Rights Reserved. Use is subject to license terms.