org.springframework.batch.core.jsr

## Class JsrJobContext

- java.lang.Object
- - org.springframework.batch.core.jsr.JsrJobContext

- All Implemented Interfaces:
    javax.batch.runtime.context.JobContext

      public class JsrJobContext
      extends java.lang.Object
      implements javax.batch.runtime.context.JobContext

  Wrapper class to provide the `JobContext` functionality as specified in JSR-352. Wrapper delegates to the underlying `JobExecution` to obtain the related contextual information.
  Since:
    3.0
  Author:
    Michael Minella, Chris Schaefer, Mahmoud Ben Hassine

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `JsrJobContext()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `javax.batch.runtime.BatchStatus` | `getBatchStatus()`
    `long` | `getExecutionId()`
    `java.lang.String` | `getExitStatus()`
    `long` | `getInstanceId()`
    `java.lang.String` | `getJobName()`
    `java.util.Properties` | `getProperties()`
    `java.lang.Object` | `getTransientUserData()`
    `void` | `setExitStatus(java.lang.String status)`
    `void` | `setJobExecution(JobExecution jobExecution)`
    `void` | `setProperties(java.util.Properties properties)`
    `void` | `setTransientUserData(java.lang.Object data)`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### JsrJobContext

          public JsrJobContext()

  - ### Method Detail

    - #### setJobExecution

          public void setJobExecution(JobExecution jobExecution)

    - #### setProperties

          public void setProperties(@Nullable
                                    java.util.Properties properties)

    - #### getJobName

          public java.lang.String getJobName()

      Specified by:
        `getJobName` in interface `javax.batch.runtime.context.JobContext`

    - #### getTransientUserData

          public java.lang.Object getTransientUserData()

      Specified by:
        `getTransientUserData` in interface `javax.batch.runtime.context.JobContext`

    - #### setTransientUserData

          public void setTransientUserData(java.lang.Object data)

      Specified by:
        `setTransientUserData` in interface `javax.batch.runtime.context.JobContext`

    - #### getInstanceId

          public long getInstanceId()

      Specified by:
        `getInstanceId` in interface `javax.batch.runtime.context.JobContext`

    - #### getExecutionId

          public long getExecutionId()

      Specified by:
        `getExecutionId` in interface `javax.batch.runtime.context.JobContext`

    - #### getProperties

          public java.util.Properties getProperties()

      Specified by:
        `getProperties` in interface `javax.batch.runtime.context.JobContext`

    - #### getBatchStatus

          public javax.batch.runtime.BatchStatus getBatchStatus()

      Specified by:
        `getBatchStatus` in interface `javax.batch.runtime.context.JobContext`

    - #### getExitStatus

          @Nullable
          public java.lang.String getExitStatus()

      Specified by:
        `getExitStatus` in interface `javax.batch.runtime.context.JobContext`

    - #### setExitStatus

          public void setExitStatus(java.lang.String status)

      Specified by:
        `setExitStatus` in interface `javax.batch.runtime.context.JobContext`