|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.springframework.batch.repeat.context.SynchronizedAttributeAccessor
org.springframework.batch.core.scope.context.StepContext
public class StepContext
Simple implementation of StepContext.
| Constructor Summary | |
|---|---|
StepContext(StepExecution stepExecution)
Create a new instance of StepContext for this
StepExecution. |
|
| Method Summary | |
|---|---|
void |
close()
Clean up the context at the end of a step execution. |
boolean |
equals(java.lang.Object other)
Extend the base class method to include the step execution itself as a key (i.e. |
java.lang.String |
getId()
|
java.util.Map<java.lang.String,java.lang.Object> |
getJobExecutionContext()
|
java.lang.String |
getJobName()
Convenient accessor for current job name identifier. |
java.util.Map<java.lang.String,java.lang.Object> |
getJobParameters()
|
StepExecution |
getStepExecution()
|
java.util.Map<java.lang.String,java.lang.Object> |
getStepExecutionContext()
|
java.lang.String |
getStepName()
Convenient accessor for current step name identifier. |
java.util.Properties |
getSystemProperties()
Convenient accessor for System properties to make it easy to access them from placeholder expressions. |
int |
hashCode()
Overrides the default behaviour to provide a hash code based only on the step execution. |
void |
registerDestructionCallback(java.lang.String name,
java.lang.Runnable callback)
Allow clients to register callbacks for clean up on close. |
java.lang.Object |
removeAttribute(java.lang.String name)
Override base class behaviour to ensure destruction callbacks are unregistered as well as the default behaviour. |
java.lang.String |
toString()
|
| Methods inherited from class org.springframework.batch.repeat.context.SynchronizedAttributeAccessor |
|---|
attributeNames, getAttribute, hasAttribute, setAttribute, setAttributeIfAbsent |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public StepContext(StepExecution stepExecution)
StepContext for this
StepExecution.
stepExecution - a step execution| Method Detail |
|---|
public java.lang.String getStepName()
StepExecutionpublic java.lang.String getJobName()
JobInstance
associated with the current StepExecutionpublic java.util.Properties getSystemProperties()
public java.util.Map<java.lang.String,java.lang.Object> getStepExecutionContext()
ExecutionContextpublic java.util.Map<java.lang.String,java.lang.Object> getJobExecutionContext()
ExecutionContextpublic java.util.Map<java.lang.String,java.lang.Object> getJobParameters()
JobParameters
public void registerDestructionCallback(java.lang.String name,
java.lang.Runnable callback)
name - the callback id (unique attribute key in this context)callback - a callback to execute on closepublic java.lang.Object removeAttribute(java.lang.String name)
removeAttribute in interface org.springframework.core.AttributeAccessorremoveAttribute in class org.springframework.batch.repeat.context.SynchronizedAttributeAccessorSynchronizedAttributeAccessor.removeAttribute(String)public void close()
StepScope.
public StepExecution getStepExecution()
public java.lang.String getId()
public boolean equals(java.lang.Object other)
equals in class org.springframework.batch.repeat.context.SynchronizedAttributeAccessorSynchronizedAttributeAccessor.equals(Object)public int hashCode()
hashCode in class org.springframework.batch.repeat.context.SynchronizedAttributeAccessorSynchronizedAttributeAccessor.hashCode()public java.lang.String toString()
toString in class org.springframework.batch.repeat.context.SynchronizedAttributeAccessor
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||