org.springframework.batch.admin.web
Class BindingHttpMessageConverter<T>

java.lang.Object
  extended by org.springframework.batch.admin.web.BindingHttpMessageConverter<T>
All Implemented Interfaces:
BeanFactoryAware, HttpMessageConverter<T>

public class BindingHttpMessageConverter<T>
extends Object
implements HttpMessageConverter<T>, BeanFactoryAware


Constructor Summary
BindingHttpMessageConverter()
           
 
Method Summary
 boolean canRead(Class<?> clazz, MediaType mediaType)
           
 boolean canWrite(Class<?> clazz, MediaType mediaType)
           
 List<MediaType> getSupportedMediaTypes()
           
 T read(Class<? extends T> clazz, HttpInputMessage inputMessage)
           
 void setBeanFactory(BeanFactory beanFactory)
           
 void setTargetType(Class<T> targetType)
           
 void write(T input, MediaType contentType, HttpOutputMessage outputMessage)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BindingHttpMessageConverter

public BindingHttpMessageConverter()
Method Detail

setBeanFactory

public void setBeanFactory(BeanFactory beanFactory)
                    throws BeansException
Specified by:
setBeanFactory in interface BeanFactoryAware
Throws:
BeansException

setTargetType

public void setTargetType(Class<T> targetType)
Parameters:
targetType - the tergetType to set

getSupportedMediaTypes

public List<MediaType> getSupportedMediaTypes()
Specified by:
getSupportedMediaTypes in interface HttpMessageConverter<T>

canRead

public boolean canRead(Class<?> clazz,
                       MediaType mediaType)
Specified by:
canRead in interface HttpMessageConverter<T>

canWrite

public boolean canWrite(Class<?> clazz,
                        MediaType mediaType)
Specified by:
canWrite in interface HttpMessageConverter<T>

read

public T read(Class<? extends T> clazz,
              HttpInputMessage inputMessage)
       throws IOException,
              HttpMessageNotReadableException
Specified by:
read in interface HttpMessageConverter<T>
Throws:
IOException
HttpMessageNotReadableException

write

public void write(T input,
                  MediaType contentType,
                  HttpOutputMessage outputMessage)
           throws IOException,
                  HttpMessageNotWritableException
Specified by:
write in interface HttpMessageConverter<T>
Throws:
IOException
HttpMessageNotWritableException


Copyright © 2011. All Rights Reserved.