Class SystemCommandExecuterFactory
- java.lang.Object
-
- com.github.toolarium.system.command.SystemCommandExecuterFactory
-
public final class SystemCommandExecuterFactory extends java.lang.Object
The system command excuter factory
-
-
Field Summary
Fields Modifier and Type Field Description static long
INITIAL_DELAY
Get the default initial delay of the folder cleanup servicestatic long
PERIOD
Get the default period of the folder cleanup servicestatic java.util.concurrent.TimeUnit
TIMEUNIT
Get the default timeunit of the folder cleanup service
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ISystemCommandExecuterTypeBuilder
builder()
Create a system command executer type builderISystemCommandExecuter
createSystemCommandExecuter(ISystemCommand... systemCommand)
Create a system command executerISystemCommandExecuter
createSystemCommandExecuter(ISystemCommandGroupList systemCommandGroupList)
Create a system command executerstatic SystemCommandExecuterFactory
getInstance()
Get the instancejava.nio.file.Path
getScriptFolderBasePath()
Get the script folder base pathvoid
setScriptFolderBasePath(java.nio.file.Path inputBasePath)
Set the script folder base pathvoid
startFolderCleanupService()
Start the folder cleanup servicevoid
startFolderCleanupService(long initialDelay, long period, java.util.concurrent.TimeUnit timeUnit)
Start the folder cleanup servicevoid
startFolderCleanupService(long initialDelay, long period, java.util.concurrent.TimeUnit timeUnit, long lockFolderThreshold)
Start the folder cleanup servicevoid
stopFolderCleanupService()
Stop the folder cleanup service
-
-
-
Field Detail
-
INITIAL_DELAY
public static final long INITIAL_DELAY
Get the default initial delay of the folder cleanup service- See Also:
- Constant Field Values
-
PERIOD
public static final long PERIOD
Get the default period of the folder cleanup service- See Also:
- Constant Field Values
-
TIMEUNIT
public static final java.util.concurrent.TimeUnit TIMEUNIT
Get the default timeunit of the folder cleanup service
-
-
Method Detail
-
getInstance
public static SystemCommandExecuterFactory getInstance()
Get the instance- Returns:
- the instance
-
builder
public static ISystemCommandExecuterTypeBuilder builder()
Create a system command executer type builder- Returns:
- the system command executer type builder
-
createSystemCommandExecuter
public ISystemCommandExecuter createSystemCommandExecuter(ISystemCommand... systemCommand)
Create a system command executer- Parameters:
systemCommand
- the system command- Returns:
- the system command executer
-
createSystemCommandExecuter
public ISystemCommandExecuter createSystemCommandExecuter(ISystemCommandGroupList systemCommandGroupList)
Create a system command executer- Parameters:
systemCommandGroupList
- the system commandm group list- Returns:
- the system command executer
-
startFolderCleanupService
public void startFolderCleanupService()
Start the folder cleanup service
-
startFolderCleanupService
public void startFolderCleanupService(long initialDelay, long period, java.util.concurrent.TimeUnit timeUnit)
Start the folder cleanup service- Parameters:
initialDelay
- the time to delay first executionperiod
- the period between successive executionstimeUnit
- the time unit of the initialDelay and period parameters
-
startFolderCleanupService
public void startFolderCleanupService(long initialDelay, long period, java.util.concurrent.TimeUnit timeUnit, long lockFolderThreshold)
Start the folder cleanup service- Parameters:
initialDelay
- the time to delay first executionperiod
- the period between successive executionstimeUnit
- the time unit of the initialDelay and period parameterslockFolderThreshold
- the lock folder threshold
-
stopFolderCleanupService
public void stopFolderCleanupService()
Stop the folder cleanup service
-
getScriptFolderBasePath
public java.nio.file.Path getScriptFolderBasePath()
Get the script folder base path- Returns:
- the script folder base path
-
setScriptFolderBasePath
public void setScriptFolderBasePath(java.nio.file.Path inputBasePath)
Set the script folder base path- Parameters:
inputBasePath
- the script folder base path
-
-