Class HierarchicalPropertyEntityProvider
java.lang.Object
org.exoplatform.services.rest.ext.provider.HierarchicalPropertyEntityProvider
- All Implemented Interfaces:
javax.ws.rs.ext.MessageBodyReader<org.exoplatform.common.util.HierarchicalProperty>,javax.ws.rs.ext.MessageBodyWriter<org.exoplatform.common.util.HierarchicalProperty>,org.exoplatform.services.rest.provider.EntityProvider<org.exoplatform.common.util.HierarchicalProperty>
@Provider
public class HierarchicalPropertyEntityProvider
extends Object
implements org.exoplatform.services.rest.provider.EntityProvider<org.exoplatform.common.util.HierarchicalProperty>
Converts stream to
HierarchicalProperty and serializes
HierarchicalProperty in given stream.- Version:
- $Id: HierarchicalPropertyEntityProvider.java
- Author:
- Dmytro Katayev
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionlonggetSize(org.exoplatform.common.util.HierarchicalProperty t, Class<?> type, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mediaType) booleanisReadable(Class<?> type, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mediaType) booleanisWriteable(Class<?> type, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mediaType) org.exoplatform.common.util.HierarchicalPropertyreadFrom(Class<org.exoplatform.common.util.HierarchicalProperty> t, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mediaType, javax.ws.rs.core.MultivaluedMap<String, String> httpHeaders, InputStream entityStream) voidwriteTo(org.exoplatform.common.util.HierarchicalProperty t, Class<?> type, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mediaType, javax.ws.rs.core.MultivaluedMap<String, Object> httpHeaders, OutputStream entityStream)
-
Constructor Details
-
HierarchicalPropertyEntityProvider
public HierarchicalPropertyEntityProvider()
-
-
Method Details
-
isReadable
public boolean isReadable(Class<?> type, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mediaType) - Specified by:
isReadablein interfacejavax.ws.rs.ext.MessageBodyReader<org.exoplatform.common.util.HierarchicalProperty>
-
readFrom
public org.exoplatform.common.util.HierarchicalProperty readFrom(Class<org.exoplatform.common.util.HierarchicalProperty> t, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mediaType, javax.ws.rs.core.MultivaluedMap<String, String> httpHeaders, InputStream entityStream) throws IOException, javax.ws.rs.WebApplicationException- Specified by:
readFromin interfacejavax.ws.rs.ext.MessageBodyReader<org.exoplatform.common.util.HierarchicalProperty>- Throws:
IOExceptionjavax.ws.rs.WebApplicationException
-
getSize
public long getSize(org.exoplatform.common.util.HierarchicalProperty t, Class<?> type, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mediaType) - Specified by:
getSizein interfacejavax.ws.rs.ext.MessageBodyWriter<org.exoplatform.common.util.HierarchicalProperty>
-
isWriteable
public boolean isWriteable(Class<?> type, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mediaType) - Specified by:
isWriteablein interfacejavax.ws.rs.ext.MessageBodyWriter<org.exoplatform.common.util.HierarchicalProperty>
-
writeTo
public void writeTo(org.exoplatform.common.util.HierarchicalProperty t, 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- Specified by:
writeToin interfacejavax.ws.rs.ext.MessageBodyWriter<org.exoplatform.common.util.HierarchicalProperty>- Throws:
IOExceptionjavax.ws.rs.WebApplicationException
-