org.springframework.integration.http
Class MultipartAwareFormHttpMessageConverter
java.lang.Object
org.springframework.integration.http.MultipartAwareFormHttpMessageConverter
- All Implemented Interfaces:
- HttpMessageConverter<MultiValueMap<String,?>>
public class MultipartAwareFormHttpMessageConverter
- extends Object
- implements HttpMessageConverter<MultiValueMap<String,?>>
An HttpMessageConverter
implementation that delegates to an instance of
XmlAwareFormHttpMessageConverter
while adding the capability to read
multipart/form-data
content in an HTTP request.
- Since:
- 2.0
- Author:
- Mark Fisher
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
MultipartAwareFormHttpMessageConverter
public MultipartAwareFormHttpMessageConverter()
setCharset
public void setCharset(Charset charset)
- Sets the character set used for writing form data.
setMultipartFileReader
public void setMultipartFileReader(MultipartFileReader<?> multipartFileReader)
- Specify the
MultipartFileReader
to use when reading MultipartFile
content.
getSupportedMediaTypes
public List<MediaType> getSupportedMediaTypes()
- Specified by:
getSupportedMediaTypes
in interface HttpMessageConverter<MultiValueMap<String,?>>
canRead
public boolean canRead(Class<?> clazz,
MediaType mediaType)
- Specified by:
canRead
in interface HttpMessageConverter<MultiValueMap<String,?>>
canWrite
public boolean canWrite(Class<?> clazz,
MediaType mediaType)
- Specified by:
canWrite
in interface HttpMessageConverter<MultiValueMap<String,?>>
read
public MultiValueMap<String,?> read(Class<? extends MultiValueMap<String,?>> clazz,
HttpInputMessage inputMessage)
throws IOException,
HttpMessageNotReadableException
- Specified by:
read
in interface HttpMessageConverter<MultiValueMap<String,?>>
- Throws:
IOException
HttpMessageNotReadableException
write
public void write(MultiValueMap<String,?> map,
MediaType contentType,
HttpOutputMessage outputMessage)
throws IOException,
HttpMessageNotWritableException
- Specified by:
write
in interface HttpMessageConverter<MultiValueMap<String,?>>
- Throws:
IOException
HttpMessageNotWritableException
Copyright © 2010. All Rights Reserved.