@Provider @Produces(value="application/json") @Consumes(value="application/json") public final class AegisJSONProvider<T> extends AegisElementProvider<T>
readXsiType, resolver, writeXsiType
Constructor and Description |
---|
AegisJSONProvider() |
Modifier and Type | Method and Description |
---|---|
protected XMLStreamReader |
createStreamReader(AegisType typeToRead,
InputStream is) |
protected XMLStreamWriter |
createStreamWriter(QName typeQName,
String enc,
OutputStream os) |
boolean |
isReadable(Class<?> type,
Type genericType,
Annotation[] annotations,
javax.ws.rs.core.MediaType mt) |
void |
setArrayKeys(List<String> keys) |
void |
setDropRootElement(boolean dropRootElement) |
void |
setIgnoreNamespaces(boolean ignoreNamespaces) |
void |
setNamespaceMap(Map<String,String> nsMap) |
void |
setSerializeAsArray(boolean asArray) |
void |
writeTo(T obj,
Class<?> type,
Type genericType,
Annotation[] anns,
javax.ws.rs.core.MediaType m,
javax.ws.rs.core.MultivaluedMap<String,Object> headers,
OutputStream os) |
readFrom
getAegisContext, getSize, isSupported, isWriteable, setReadXsiType, setWriteXsiType
public void setIgnoreNamespaces(boolean ignoreNamespaces)
public void setDropRootElement(boolean dropRootElement)
public void setSerializeAsArray(boolean asArray)
public boolean isReadable(Class<?> type, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mt)
isReadable
in interface javax.ws.rs.ext.MessageBodyReader<T>
isReadable
in class AbstractAegisProvider<T>
public void writeTo(T obj, Class<?> type, Type genericType, Annotation[] anns, javax.ws.rs.core.MediaType m, javax.ws.rs.core.MultivaluedMap<String,Object> headers, OutputStream os) throws IOException
writeTo
in interface javax.ws.rs.ext.MessageBodyWriter<T>
writeTo
in class AegisElementProvider<T>
IOException
protected XMLStreamWriter createStreamWriter(QName typeQName, String enc, OutputStream os) throws Exception
createStreamWriter
in class AegisElementProvider<T>
Exception
protected XMLStreamReader createStreamReader(AegisType typeToRead, InputStream is) throws Exception
createStreamReader
in class AegisElementProvider<T>
Exception
Apache CXF