public class JettisonListElementProvider extends AbstractCollectionJaxbProvider
Modifier and Type | Class and Description |
---|---|
static class |
JettisonListElementProvider.App |
static class |
JettisonListElementProvider.General |
AbstractCollectionJaxbProvider.JaxbTypeChecker
UTF8
Modifier and Type | Method and Description |
---|---|
protected XMLStreamReader |
getXMLStreamReader(Class<?> elementType,
MediaType mediaType,
Unmarshaller u,
InputStream entityStream)
Get the
XMLStreamReader for unmarshalling. |
boolean |
isReadable(Class<?> type,
Type genericType,
Annotation[] annotations,
MediaType mediaType) |
boolean |
isWriteable(Class<?> type,
Type genericType,
Annotation[] annotations,
MediaType mediaType) |
void |
writeCollection(Class<?> elementType,
Collection<?> t,
MediaType mediaType,
Charset c,
Marshaller m,
OutputStream entityStream)
Write a collection of JAXB objects as child elements of the root element.
|
getElementClass, getElementName, getRootElementName, readFrom, verifyArrayType, verifyCollectionSubclass, verifyGenericType, writeTo
getMarshaller, getSAXSource, getStoredJaxbContext, getUnmarshaller, isFormattedOutput, isSupported, isXmlRootElementProcessing, setConfiguration, setHeader
getCharset, getSize, readFromAsString, writeTo, writeTo, writeToAsString
public boolean isReadable(Class<?> type, Type genericType, Annotation[] annotations, MediaType mediaType)
isReadable
in interface MessageBodyReader<Object>
isReadable
in class AbstractCollectionJaxbProvider
public boolean isWriteable(Class<?> type, Type genericType, Annotation[] annotations, MediaType mediaType)
isWriteable
in interface MessageBodyWriter<Object>
isWriteable
in class AbstractCollectionJaxbProvider
public final void writeCollection(Class<?> elementType, Collection<?> t, MediaType mediaType, Charset c, Marshaller m, OutputStream entityStream) throws JAXBException, IOException
AbstractCollectionJaxbProvider
writeCollection
in class AbstractCollectionJaxbProvider
elementType
- the element type in the collection.t
- the collection to marshallmediaType
- the media typec
- the charsetm
- the marshallerentityStream
- the output stream to marshall the collectionJAXBException
- in case the marshalling of element collection fails.IOException
- in case of any other I/O error while marshalling the collection of JAXB objects.protected final XMLStreamReader getXMLStreamReader(Class<?> elementType, MediaType mediaType, Unmarshaller u, InputStream entityStream) throws XMLStreamException
AbstractCollectionJaxbProvider
XMLStreamReader
for unmarshalling.getXMLStreamReader
in class AbstractCollectionJaxbProvider
elementType
- the individual element type.mediaType
- the media type.u
- the unmarshaller as a carrier of possible config options.entityStream
- the input stream.XMLStreamException
- in case XMLStreamReader
retrieval fails.Copyright © 2007-2024, Oracle and/or its affiliates. All Rights Reserved. Use is subject to license terms.