org.springframework.batch.admin.service
Class JobLocatorStepLocator

java.lang.Object
  extended by org.springframework.batch.admin.service.JobLocatorStepLocator
All Implemented Interfaces:
org.springframework.batch.core.step.StepLocator

public class JobLocatorStepLocator
extends java.lang.Object
implements org.springframework.batch.core.step.StepLocator

Author:
Dave Syer

Constructor Summary
JobLocatorStepLocator()
          Convenience constructor for declarative configuration.
JobLocatorStepLocator(org.springframework.batch.core.configuration.ListableJobLocator jobLocator)
          Create an instance from this JobLocator.
 
Method Summary
 org.springframework.batch.core.Step getStep(java.lang.String path)
          Locate a step by referencing it through its parent job with a separator, e.g.
 java.util.Collection<java.lang.String> getStepNames()
          Loop through all the jobs and pull out their step names.
 void setJobLocator(org.springframework.batch.core.configuration.ListableJobLocator jobLocator)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JobLocatorStepLocator

public JobLocatorStepLocator(org.springframework.batch.core.configuration.ListableJobLocator jobLocator)
Create an instance from this JobLocator.

Parameters:
jobLocator - a JobLocator

JobLocatorStepLocator

public JobLocatorStepLocator()
Convenience constructor for declarative configuration.

Method Detail

setJobLocator

public void setJobLocator(org.springframework.batch.core.configuration.ListableJobLocator jobLocator)
Parameters:
jobLocator - the jobLocator to set

getStep

public org.springframework.batch.core.Step getStep(java.lang.String path)
                                            throws org.springframework.batch.core.step.NoSuchStepException
Locate a step by referencing it through its parent job with a separator, e.g. job-name/step-name. The separator defaults to a forward slash.

Specified by:
getStep in interface org.springframework.batch.core.step.StepLocator
Throws:
org.springframework.batch.core.step.NoSuchStepException
See Also:
StepLocator.getStep(String)

getStepNames

public java.util.Collection<java.lang.String> getStepNames()
Loop through all the jobs and pull out their step names. The result is in the form that would be appropriate for getStep(String) (i.e. with a separator).

Specified by:
getStepNames in interface org.springframework.batch.core.step.StepLocator
See Also:
StepLocator.getStepNames()


Copyright © 2011. All Rights Reserved.