Class FileBodyHandler
java.lang.Object
org.jboss.resteasy.reactive.common.providers.serialisers.FileBodyHandler
- All Implemented Interfaces:
jakarta.ws.rs.ext.MessageBodyReader<File>,jakarta.ws.rs.ext.MessageBodyWriter<File>
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic FiledoRead(jakarta.ws.rs.core.MultivaluedMap<String, String> httpHeaders, InputStream entityStream, File file) protected voiddoWrite(File uploadFile, OutputStream out) booleanisReadable(Class<?> type, Type genericType, Annotation[] annotations, jakarta.ws.rs.core.MediaType mediaType) booleanisWriteable(Class<?> type, Type genericType, Annotation[] annotations, jakarta.ws.rs.core.MediaType mediaType) readFrom(Class<File> type, Type genericType, Annotation[] annotations, jakarta.ws.rs.core.MediaType mediaType, jakarta.ws.rs.core.MultivaluedMap<String, String> httpHeaders, InputStream entityStream) voidwriteTo(File uploadFile, Class<?> type, Type genericType, Annotation[] annotations, jakarta.ws.rs.core.MediaType mediaType, jakarta.ws.rs.core.MultivaluedMap<String, Object> httpHeaders, OutputStream entityStream) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface jakarta.ws.rs.ext.MessageBodyWriter
getSize
-
Field Details
-
PREFIX
- See Also:
-
SUFFIX
- See Also:
-
-
Constructor Details
-
FileBodyHandler
public FileBodyHandler()
-
-
Method Details
-
isReadable
public boolean isReadable(Class<?> type, Type genericType, Annotation[] annotations, jakarta.ws.rs.core.MediaType mediaType) - Specified by:
isReadablein interfacejakarta.ws.rs.ext.MessageBodyReader<File>
-
readFrom
public File readFrom(Class<File> type, Type genericType, Annotation[] annotations, jakarta.ws.rs.core.MediaType mediaType, jakarta.ws.rs.core.MultivaluedMap<String, String> httpHeaders, InputStream entityStream) throws IOException- Specified by:
readFromin interfacejakarta.ws.rs.ext.MessageBodyReader<File>- Throws:
IOException
-
doRead
public static File doRead(jakarta.ws.rs.core.MultivaluedMap<String, String> httpHeaders, InputStream entityStream, File file) throws IOException- Throws:
IOException
-
isWriteable
public boolean isWriteable(Class<?> type, Type genericType, Annotation[] annotations, jakarta.ws.rs.core.MediaType mediaType) - Specified by:
isWriteablein interfacejakarta.ws.rs.ext.MessageBodyWriter<File>
-
writeTo
public void writeTo(File uploadFile, Class<?> type, Type genericType, Annotation[] annotations, jakarta.ws.rs.core.MediaType mediaType, jakarta.ws.rs.core.MultivaluedMap<String, Object> httpHeaders, OutputStream entityStream) throws IOException- Specified by:
writeToin interfacejakarta.ws.rs.ext.MessageBodyWriter<File>- Throws:
IOException
-
doWrite
- Throws:
IOException
-