org.springframework.batch.core.launch.support
Class SimpleJvmExitCodeMapper
java.lang.Object
org.springframework.batch.core.launch.support.SimpleJvmExitCodeMapper
- All Implemented Interfaces:
- ExitCodeMapper
public class SimpleJvmExitCodeMapper
- extends Object
- implements ExitCodeMapper
An implementation of ExitCodeMapper
that can be configured through a
map from batch exit codes (String) to integer results. Some default entries
are set up to recognise common cases. Any that are injected are added to these.
- Author:
- Stijn Maller, Lucas Ward, Dave Syer
Field Summary |
protected org.apache.commons.logging.Log |
logger
|
Method Summary |
Map |
getMapping()
|
int |
intValue(String exitCode)
Get the operating system exit status that matches a certain Batch
Framework Exitcode |
void |
setMapping(Map exitCodeMap)
Supply the ExitCodeMappings |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
logger
protected org.apache.commons.logging.Log logger
SimpleJvmExitCodeMapper
public SimpleJvmExitCodeMapper()
getMapping
public Map getMapping()
setMapping
public void setMapping(Map exitCodeMap)
- Supply the ExitCodeMappings
- Parameters:
exitCodeMap
- A set of mappings between environment specific exit
codes and batch framework internal exit codes
intValue
public int intValue(String exitCode)
- Get the operating system exit status that matches a certain Batch
Framework Exitcode
- Specified by:
intValue
in interface ExitCodeMapper
- Parameters:
exitCode
- The exitcode of the Batch Job as known by the Batch
Framework
- Returns:
- The exitCode of the Batch Job as known by the JVM
Copyright © 2009 SpringSource. All Rights Reserved.