protected static class DefaultTileMaster.StateSaver extends java.lang.Object implements JobRunnerListener
Constructor and Description |
---|
DefaultTileMaster.StateSaver()
The Constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
addJob(JobBuildConfig processed, JobState state)
Updates the tiling task.
|
protected boolean |
copyFileQuietly(java.io.File file, java.io.File bakFile) |
protected void |
deleteBakFile(java.io.File bakFile) |
void |
dispose()
Release resources.
|
protected java.io.File |
getConfigFile(java.lang.String key) |
protected java.io.File |
getStateFile(java.lang.String key) |
void |
load()
Read the tiling information from the configuration file.
|
void |
notifyStateInited(JobBuildConfig config, JobState state)
Marks the type of the task to be initialization completed.
|
void |
notifyStateUpdated(JobBuildConfig config, JobState state)
Marks the type of the task to be update completed.
|
protected <T> T |
read(java.lang.Class<T> clz, java.lang.String nodeName, java.io.File file) |
boolean |
remove(java.lang.String jobID)
Deletes the corresponding configuration file information through the job ID.
|
void |
setDefaultTileMaster(DefaultTileMaster value)
Setting tiling master node.
|
void |
setDirectory(java.io.File value)
Sets the output folder.
|
protected boolean |
writeContentToFile(java.lang.String content, java.io.File file) |
public DefaultTileMaster.StateSaver()
The Constructor.
public void dispose()
Release resources.
public void setDirectory(java.io.File value) throws java.io.IOException
Sets the output folder.
value
-java.io.IOException
public void setDefaultTileMaster(DefaultTileMaster value)
Setting tiling master node.
value
-public void addJob(JobBuildConfig processed, JobState state)
Updates the tiling task.
processor
-state
-public void load()
Read the tiling information from the configuration file.
public void notifyStateInited(JobBuildConfig config, JobState state)
JobRunnerListener
Marks the type of the task to be initialization completed.
notifyStateInited
in interface JobRunnerListener
public void notifyStateUpdated(JobBuildConfig config, JobState state)
JobRunnerListener
Marks the type of the task to be update completed.
notifyStateUpdated
in interface JobRunnerListener
public boolean remove(java.lang.String jobID)
Deletes the corresponding configuration file information through the job ID.
jobID
-protected <T> T read(java.lang.Class<T> clz, java.lang.String nodeName, java.io.File file)
protected java.io.File getStateFile(java.lang.String key)
protected java.io.File getConfigFile(java.lang.String key)
protected boolean copyFileQuietly(java.io.File file, java.io.File bakFile)
protected boolean writeContentToFile(java.lang.String content, java.io.File file)
protected void deleteBakFile(java.io.File bakFile)