org.springframework.batch.core
Class JobParameter

java.lang.Object
  extended by org.springframework.batch.core.JobParameter
All Implemented Interfaces:
Serializable

public class JobParameter
extends Object
implements Serializable

Domain representation of a parameter to a batch job. Only the following types can be parameters: String, Long, Date, and Double.

Since:
2.0
Author:
Lucas Ward, Dave Syer
See Also:
Serialized Form

Nested Class Summary
static class JobParameter.ParameterType
          Enumeration representing the type of a JobParameter.
 
Constructor Summary
JobParameter(Date parameter)
          Construct a new JobParameter as a Date.
JobParameter(Double parameter)
          Construct a new JobParameter as a Double.
JobParameter(Long parameter)
          Construct a new JobParameter as a Long.
JobParameter(String parameter)
          Construct a new JobParameter as a String.
 
Method Summary
 boolean equals(Object obj)
           
 JobParameter.ParameterType getType()
           
 Object getValue()
           
 int hashCode()
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

JobParameter

public JobParameter(String parameter)
Construct a new JobParameter as a String.


JobParameter

public JobParameter(Long parameter)
Construct a new JobParameter as a Long.

Parameters:
parameter -

JobParameter

public JobParameter(Date parameter)
Construct a new JobParameter as a Date.

Parameters:
parameter -

JobParameter

public JobParameter(Double parameter)
Construct a new JobParameter as a Double.

Parameters:
parameter -
Method Detail

getValue

public Object getValue()
Returns:
the value contained within this JobParameter.

getType

public JobParameter.ParameterType getType()
Returns:
a ParameterType representing the type of this parameter.

equals

public boolean equals(Object obj)
Overrides:
equals in class Object

toString

public String toString()
Overrides:
toString in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object


Copyright © 2013 SpringSource. All Rights Reserved.