org.springframework.batch.core.repository.dao
Class XStreamExecutionContextStringSerializer
java.lang.Object
org.springframework.batch.core.repository.dao.XStreamExecutionContextStringSerializer
- All Implemented Interfaces:
- ExecutionContextStringSerializer, InitializingBean
public class XStreamExecutionContextStringSerializer
- extends Object
- implements ExecutionContextStringSerializer, InitializingBean
Implementation that uses XStream and Jettison to provide serialization.
- Since:
- 2.0
- Author:
- Thomas Risberg
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
XStreamExecutionContextStringSerializer
public XStreamExecutionContextStringSerializer()
serialize
public String serialize(Map<String,Object> context)
- Description copied from interface:
ExecutionContextStringSerializer
- Serialize the context to a string representation
- Specified by:
serialize
in interface ExecutionContextStringSerializer
- Parameters:
context
- the object that should be serialized
- Returns:
- the serialization string
deserialize
public Map<String,Object> deserialize(String context)
- Description copied from interface:
ExecutionContextStringSerializer
- De-serialize the context from a string representation
- Specified by:
deserialize
in interface ExecutionContextStringSerializer
- Parameters:
context
- the serialization string that should be de-serialized
- Returns:
- the de-serialized context map
setReflectionProvider
public void setReflectionProvider(com.thoughtworks.xstream.converters.reflection.ReflectionProvider reflectionProvider)
setHierarchicalStreamDriver
public void setHierarchicalStreamDriver(com.thoughtworks.xstream.io.HierarchicalStreamDriver hierarchicalStreamDriver)
afterPropertiesSet
public void afterPropertiesSet()
throws Exception
- Specified by:
afterPropertiesSet
in interface InitializingBean
- Throws:
Exception
init
public void init()
throws Exception
- Throws:
Exception
Copyright © 2013 SpringSource. All Rights Reserved.