Class DaemonEntry
- java.lang.Object
-
- fr.paris.lutece.portal.service.daemon.DaemonEntry
-
public final class DaemonEntry extends java.lang.Objectthis class is used to manage daemons declaration
-
-
Constructor Summary
Constructors Constructor Description DaemonEntry()Constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetClassName()Returns the ClassNameDaemonThreadgetDaemonThread()Returns the thread which start the daemon taskjava.lang.StringgetDescriptionKey()Returns the DescriptionKeyjava.lang.StringgetId()Returns the IdlonggetInterval()Returns the Interval of time in seconds between two executionsjava.lang.StringgetLastRunDate()Returns the LastRunDatejava.lang.StringgetLastRunLogs()Returns the LastRunLogsjava.lang.StringgetNameKey()Returns the NameKeyjava.lang.StringgetPluginName()Returns the PluginNamebooleanisRunning()Checks if the daemon is runningvoidloadDaemon()Load the daemonbooleanonStartup()Indicates if the daemon must be process on system startupvoidsetClassName(java.lang.String strClassName)Sets the ClassNamevoidsetDescriptionKey(java.lang.String strDescriptionKey)Sets the DescriptionKeyvoidsetId(java.lang.String strId)Sets the IdvoidsetInterval(long lInterval)Sets the intervalvoidsetIsRunning(boolean bIsRunning)Set running daemon statusvoidsetLastRunDate(java.util.Date dateLastRunDate)Sets the LastRunDatevoidsetLastRunLogs(java.lang.String strLastRunLogs)Sets the LastRunLogsvoidsetNameKey(java.lang.String strNameKey)Sets the NameKeyvoidsetOnStartUp(boolean bOnStartup)Sets the OnStartUp propertyvoidsetPluginName(java.lang.String strPluginName)Sets the PluginName
-
-
-
Method Detail
-
getId
public java.lang.String getId()
Returns the Id- Returns:
- The Id
-
setId
public void setId(java.lang.String strId)
Sets the Id- Parameters:
strId- The Id
-
getNameKey
public java.lang.String getNameKey()
Returns the NameKey- Returns:
- The NameKey
-
setNameKey
public void setNameKey(java.lang.String strNameKey)
Sets the NameKey- Parameters:
strNameKey- The NameKey
-
getDescriptionKey
public java.lang.String getDescriptionKey()
Returns the DescriptionKey- Returns:
- The DescriptionKey
-
setDescriptionKey
public void setDescriptionKey(java.lang.String strDescriptionKey)
Sets the DescriptionKey- Parameters:
strDescriptionKey- The DescriptionKey
-
getClassName
public java.lang.String getClassName()
Returns the ClassName- Returns:
- The ClassName
-
setClassName
public void setClassName(java.lang.String strClassName)
Sets the ClassName- Parameters:
strClassName- The ClassName
-
loadDaemon
public void loadDaemon() throws java.lang.ClassNotFoundException, java.lang.InstantiationException, java.lang.IllegalAccessExceptionLoad the daemon- Throws:
java.lang.ClassNotFoundException- If an error occuredjava.lang.InstantiationException- If an error occuredjava.lang.IllegalAccessException- If an error occured
-
getDaemonThread
public DaemonThread getDaemonThread()
Returns the thread which start the daemon task- Returns:
- The thread
-
getInterval
public long getInterval()
Returns the Interval of time in seconds between two executions- Returns:
- _lInterval the interval of time
-
onStartup
public boolean onStartup()
Indicates if the daemon must be process on system startup- Returns:
- _bOnStartup
-
isRunning
public boolean isRunning()
Checks if the daemon is running- Returns:
- True if the thread is running, otherwise false
-
setIsRunning
public void setIsRunning(boolean bIsRunning)
Set running daemon status- Parameters:
bIsRunning- True if the thread is running, otherwise false
-
getPluginName
public java.lang.String getPluginName()
Returns the PluginName- Returns:
- The PluginName
-
setPluginName
public void setPluginName(java.lang.String strPluginName)
Sets the PluginName- Parameters:
strPluginName- The PluginName
-
getLastRunDate
public java.lang.String getLastRunDate()
Returns the LastRunDate- Returns:
- The LastRunDate
-
setLastRunDate
public void setLastRunDate(java.util.Date dateLastRunDate)
Sets the LastRunDate- Parameters:
dateLastRunDate- The LastRunDate
-
getLastRunLogs
public java.lang.String getLastRunLogs()
Returns the LastRunLogs- Returns:
- The LastRunLogs
-
setLastRunLogs
public void setLastRunLogs(java.lang.String strLastRunLogs)
Sets the LastRunLogs- Parameters:
strLastRunLogs- The LastRunLogs
-
setInterval
public void setInterval(long lInterval)
Sets the interval- Parameters:
lInterval- The interval
-
setOnStartUp
public void setOnStartUp(boolean bOnStartup)
Sets the OnStartUp property- Parameters:
bOnStartup- True if the daemon should be launched on startup, otherwise false
-
-