Apache CXF API

org.apache.cxf.jaxrs.provider
Class StringProvider

java.lang.Object
  extended by org.apache.cxf.jaxrs.provider.StringProvider
All Implemented Interfaces:
javax.ws.rs.ext.MessageBodyReader<java.lang.String>, javax.ws.rs.ext.MessageBodyWriter<java.lang.String>

@Provider
public final class StringProvider
extends java.lang.Object
implements javax.ws.rs.ext.MessageBodyWriter<java.lang.String>, javax.ws.rs.ext.MessageBodyReader<java.lang.String>


Constructor Summary
StringProvider()
           
 
Method Summary
 long getSize(java.lang.String s)
           
 boolean isReadable(java.lang.Class<?> type, java.lang.reflect.Type genericType, java.lang.annotation.Annotation[] annotations)
           
 boolean isWriteable(java.lang.Class<?> type, java.lang.reflect.Type genericType, java.lang.annotation.Annotation[] annotations)
           
 java.lang.String readFrom(java.lang.Class<java.lang.String> clazz, java.lang.reflect.Type genericType, java.lang.annotation.Annotation[] annotations, javax.ws.rs.core.MediaType m, javax.ws.rs.core.MultivaluedMap<java.lang.String,java.lang.String> headers, java.io.InputStream is)
           
 void writeTo(java.lang.String obj, java.lang.Class<?> clazz, java.lang.reflect.Type genericType, java.lang.annotation.Annotation[] annotations, javax.ws.rs.core.MediaType m, javax.ws.rs.core.MultivaluedMap<java.lang.String,java.lang.Object> headers, java.io.OutputStream os)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StringProvider

public StringProvider()
Method Detail

isWriteable

public boolean isWriteable(java.lang.Class<?> type,
                           java.lang.reflect.Type genericType,
                           java.lang.annotation.Annotation[] annotations)
Specified by:
isWriteable in interface javax.ws.rs.ext.MessageBodyWriter<java.lang.String>

isReadable

public boolean isReadable(java.lang.Class<?> type,
                          java.lang.reflect.Type genericType,
                          java.lang.annotation.Annotation[] annotations)
Specified by:
isReadable in interface javax.ws.rs.ext.MessageBodyReader<java.lang.String>

getSize

public long getSize(java.lang.String s)
Specified by:
getSize in interface javax.ws.rs.ext.MessageBodyWriter<java.lang.String>

readFrom

public java.lang.String readFrom(java.lang.Class<java.lang.String> clazz,
                                 java.lang.reflect.Type genericType,
                                 java.lang.annotation.Annotation[] annotations,
                                 javax.ws.rs.core.MediaType m,
                                 javax.ws.rs.core.MultivaluedMap<java.lang.String,java.lang.String> headers,
                                 java.io.InputStream is)
                          throws java.io.IOException
Specified by:
readFrom in interface javax.ws.rs.ext.MessageBodyReader<java.lang.String>
Throws:
java.io.IOException

writeTo

public void writeTo(java.lang.String obj,
                    java.lang.Class<?> clazz,
                    java.lang.reflect.Type genericType,
                    java.lang.annotation.Annotation[] annotations,
                    javax.ws.rs.core.MediaType m,
                    javax.ws.rs.core.MultivaluedMap<java.lang.String,java.lang.Object> headers,
                    java.io.OutputStream os)
             throws java.io.IOException
Specified by:
writeTo in interface javax.ws.rs.ext.MessageBodyWriter<java.lang.String>
Throws:
java.io.IOException

Apache CXF API

Apache CXF