|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.sf.mybatchfwk.BatchConfiguration
public class BatchConfiguration
Configuration of the batch.
It can be load from the configuration file 'my-batch-fwk.properties' by the method getConfigurationProperties or build by the user.
| Field Summary | |
|---|---|
static java.lang.String |
CONFIGURATION_FILENAME
The name of the configuration file |
static java.lang.String |
DATE_FORMAT
The date format use to parse dates stored into the configuration file |
| Constructor Summary | |
|---|---|
BatchConfiguration()
Default constructor: the default behavior is applicated. |
|
BatchConfiguration(java.util.Properties properties)
Init the configuration from properties. |
|
| Method Summary | |
|---|---|
protected void |
checkConsistency()
Check the consistency of the configuration: - the min size of the thread pool cannot be greater than the max size. |
java.lang.String |
getBatchClassName()
|
int |
getBlockingQueueCapacity()
|
java.lang.String |
getExecutionHistoryClassName()
|
java.lang.String |
getExecutionReportClassName()
|
PropertiesLoader |
getPropertiesLoader()
|
java.util.Date |
getScheduleEndDate()
|
long |
getScheduleNumberOfLoop()
|
long |
getSchedulePeriodTime()
|
java.util.Date |
getScheduleStartDate()
|
int |
getThreadPoolMaxSize()
|
int |
getThreadPoolMinSize()
|
boolean |
isDeferredStart()
|
boolean |
isExecuteCompletedTasks()
|
boolean |
isExecuteFailedTasks()
|
boolean |
isExecuteNewTasks()
|
boolean |
isJmxEnable()
|
boolean |
isJmxEnableNotifications()
|
boolean |
isScheduleEnable()
|
boolean |
isStayAliveAfterShutdown()
|
boolean |
isTaskFilterEnable()
Return true if the tasks mut be filtered before to be execute |
void |
setBatchClass(java.lang.Class batchClass)
|
void |
setBatchClassName(java.lang.String batchClassName)
|
void |
setBlockingQueueCapacity(int blockingQueueCapacity)
|
void |
setDeferredStart(boolean batchDeferredStart)
|
void |
setExecuteCompletedTasks(boolean executeCompletedTasks)
|
void |
setExecuteFailedTasks(boolean executeFailedTasks)
|
void |
setExecuteNewTasks(boolean executeNewTasks)
|
void |
setExecutionHistoryClass(java.lang.Class executionHistoryClass)
|
void |
setExecutionHistoryClassName(java.lang.String historyStorageClassName)
|
void |
setExecutionReportClass(java.lang.Class executionReportClass)
|
void |
setExecutionReportClassName(java.lang.String executionReportClassName)
|
void |
setJmxEnable(boolean jmxEnable)
|
void |
setJmxEnableNotifications(boolean jmxEnableNotifications)
|
void |
setPropertiesLoader(PropertiesLoader propertiesManager)
|
void |
setScheduleEnable(boolean scheduleEnabled)
|
void |
setScheduleEndDate(java.util.Date scheduleEndDate)
|
void |
setScheduleNumberOfLoop(long scheduleNumberOfLoop)
|
void |
setSchedulePeriodTime(long schedulePeriodTime)
|
void |
setScheduleStartDate(java.util.Date scheduleStartDate)
|
void |
setStayAliveAfterShutdown(boolean stayAliveAfterShutdown)
|
void |
setThreadPoolMaxSize(int threadPoolMaxSize)
|
void |
setThreadPoolMinSize(int threadPoolMinSize)
|
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String CONFIGURATION_FILENAME
public static final java.lang.String DATE_FORMAT
| Constructor Detail |
|---|
public BatchConfiguration()
public BatchConfiguration(java.util.Properties properties)
throws BatchException
properties - properties (most of the time build by the getConfigurationProperties method)
BatchException - if a parameter is not of the waiting type| Method Detail |
|---|
protected void checkConsistency()
throws BatchException
BatchExceptionpublic java.lang.String toString()
toString in class java.lang.Objectpublic void setExecutionHistoryClass(java.lang.Class executionHistoryClass)
executionHistoryClass - public void setExecutionReportClass(java.lang.Class executionReportClass)
executionReportClass - public void setBatchClass(java.lang.Class batchClass)
batchClass - public boolean isTaskFilterEnable()
public java.lang.String getBatchClassName()
public void setBatchClassName(java.lang.String batchClassName)
batchClassName - the batchClassName to setpublic boolean isScheduleEnable()
public void setScheduleEnable(boolean scheduleEnabled)
scheduleEnable - the scheduleEnable to setpublic java.util.Date getScheduleEndDate()
public void setScheduleEndDate(java.util.Date scheduleEndDate)
scheduleEndDate - the scheduleEndDate to setpublic long getScheduleNumberOfLoop()
public void setScheduleNumberOfLoop(long scheduleNumberOfLoop)
scheduleNumberOfLoop - the scheduleNumberOfLoop to setpublic long getSchedulePeriodTime()
public void setSchedulePeriodTime(long schedulePeriodTime)
schedulePeriodTime - the schedulePeriodTime to setpublic java.util.Date getScheduleStartDate()
public void setScheduleStartDate(java.util.Date scheduleStartDate)
scheduleStartDate - the scheduleStartDate to setpublic int getThreadPoolMaxSize()
public void setThreadPoolMaxSize(int threadPoolMaxSize)
threadPoolMaxSize - the threadPoolMaxSize to setpublic int getThreadPoolMinSize()
public void setThreadPoolMinSize(int threadPoolMinSize)
threadPoolMinSize - the threadPoolMinSize to setpublic boolean isDeferredStart()
public void setDeferredStart(boolean batchDeferredStart)
deferredStart - the deferredStart to setpublic boolean isStayAliveAfterShutdown()
public void setStayAliveAfterShutdown(boolean stayAliveAfterShutdown)
stayAliveAfterShutdown - the stayAliveAfterShutdown to setpublic boolean isJmxEnable()
public void setJmxEnable(boolean jmxEnable)
jmxEnable - The jmxEnable to set.public boolean isJmxEnableNotifications()
public void setJmxEnableNotifications(boolean jmxEnableNotifications)
jmxEnableNotifications - The jmxEnableNotifications to set.public java.lang.String getExecutionReportClassName()
public void setExecutionReportClassName(java.lang.String executionReportClassName)
executionReportClassName - The executionReportClassName to set.public int getBlockingQueueCapacity()
public void setBlockingQueueCapacity(int blockingQueueCapacity)
blockingQueueCapacity - The blockingQueueCapacity to set.public java.lang.String getExecutionHistoryClassName()
public void setExecutionHistoryClassName(java.lang.String historyStorageClassName)
executionHistoryClassName - The executionHistoryClassName to set.public boolean isExecuteCompletedTasks()
public void setExecuteCompletedTasks(boolean executeCompletedTasks)
executeCompletedTasks - The executeCompletedTasks to set.public boolean isExecuteFailedTasks()
public void setExecuteFailedTasks(boolean executeFailedTasks)
executeFailedTasks - The executeFailedTasks to set.public boolean isExecuteNewTasks()
public void setExecuteNewTasks(boolean executeNewTasks)
executeNewTasks - The executeNewTasks to set.public PropertiesLoader getPropertiesLoader()
public void setPropertiesLoader(PropertiesLoader propertiesManager)
propertiesLoader - the propertiesLoader to set
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||