@Provider public class TaskListWriter extends EntityListWriter<Task>
factory
Constructor and Description |
---|
TaskListWriter() |
Modifier and Type | Method and Description |
---|---|
protected String |
getEntityType()
Returns the entity-type value of the list (ie: users, groups....)
|
protected void |
writeItem(org.codehaus.jackson.JsonGenerator jg,
Task item)
Writes the item in a JsonGenerator.
|
void |
writeTo(List<Task> tasks,
Class<?> type,
Type genericType,
Annotation[] annotations,
javax.ws.rs.core.MediaType mediaType,
javax.ws.rs.core.MultivaluedMap<String,Object> httpHeaders,
OutputStream entityStream) |
isWriteable, writeEntityBody, writeHeader, writePaginableHeader
getSize, writeEntity
public TaskListWriter()
protected String getEntityType()
EntityListWriter
getEntityType
in class EntityListWriter<Task>
protected void writeItem(org.codehaus.jackson.JsonGenerator jg, Task item) throws IOException
EntityListWriter
writeItem
in class EntityListWriter<Task>
IOException
public void writeTo(List<Task> tasks, Class<?> type, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mediaType, javax.ws.rs.core.MultivaluedMap<String,Object> httpHeaders, OutputStream entityStream) throws IOException, javax.ws.rs.WebApplicationException
writeTo
in interface javax.ws.rs.ext.MessageBodyWriter<List<Task>>
writeTo
in class EntityWriter<List<Task>>
IOException
javax.ws.rs.WebApplicationException
Copyright © 2015 Nuxeo SA. All rights reserved.