Class PentahoBlockoutManager
- java.lang.Object
-
- org.pentaho.platform.scheduler2.blockout.PentahoBlockoutManager
-
- All Implemented Interfaces:
IBlockoutManager
public class PentahoBlockoutManager extends Object implements IBlockoutManager
-
-
Field Summary
-
Fields inherited from interface org.pentaho.platform.api.scheduler2.IBlockoutManager
BLOCK_OUT_JOB_NAME, DURATION_PARAM, SCHEDULED_FIRE_TIME, TIME_ZONE_PARAM
-
-
Constructor Summary
Constructors Constructor Description PentahoBlockoutManager()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description IJobTrigger
getBlockOut(String blockOutJobId)
List<Job>
getBlockOutJobs()
boolean
isPartiallyBlocked(IJobTrigger scheduleJobTrigger)
boolean
shouldFireNow()
List<IJobTrigger>
willBlockSchedules(IJobTrigger testBlockOutJobTrigger)
boolean
willFire(IJobTrigger scheduleTrigger)
-
-
-
Method Detail
-
getBlockOut
public IJobTrigger getBlockOut(String blockOutJobId)
- Specified by:
getBlockOut
in interfaceIBlockoutManager
- Returns:
- a IBlockOutTrigger that represents the blockOut with the name blockOutName
-
getBlockOutJobs
public List<Job> getBlockOutJobs()
- Specified by:
getBlockOutJobs
in interfaceIBlockoutManager
- Returns:
- a list of jobs essentially should be used instead of getBlockOuts which is deprecated
-
willFire
public boolean willFire(IJobTrigger scheduleTrigger)
- Specified by:
willFire
in interfaceIBlockoutManager
- Parameters:
scheduleTrigger
-IJobTrigger
- Returns:
- whether the
IJobTrigger
will fire, at least once, given the current list ofIJobTrigger
s
-
shouldFireNow
public boolean shouldFireNow()
- Specified by:
shouldFireNow
in interfaceIBlockoutManager
- Returns:
- true if there are no current blockOuts active at the moment this method is called
-
willBlockSchedules
public List<IJobTrigger> willBlockSchedules(IJobTrigger testBlockOutJobTrigger)
- Specified by:
willBlockSchedules
in interfaceIBlockoutManager
- Returns:
- the
List
ofIJobTrigger
s which would be blocked by theIJobTrigger
-
isPartiallyBlocked
public boolean isPartiallyBlocked(IJobTrigger scheduleJobTrigger)
- Specified by:
isPartiallyBlocked
in interfaceIBlockoutManager
- Parameters:
scheduleJobTrigger
-IJobTrigger
- Returns:
- whether the
IJobTrigger
is blocked, at least partially, by at least a singleIJobTrigger
, provided the list of registeredIJobTrigger
s
-
-