|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.fuin.kickstart4j.ConfigUpdater
public final class ConfigUpdater
Creates or updates a configuration.
| Nested Class Summary | |
|---|---|
protected static class |
ConfigUpdater.DefaultListener
Outputs events to the console. |
| Constructor Summary | |
|---|---|
ConfigUpdater()
Default constructor. |
|
ConfigUpdater(ConfigUpdaterListener listener)
Constructor with listener. |
|
ConfigUpdater(java.io.File configFile)
Constructor with configuration file. |
|
ConfigUpdater(java.io.File configFile,
ConfigUpdaterListener listener)
Constructor with configuration file and log printer. |
|
| Method Summary | |
|---|---|
Config |
getConfig()
Returns the configuration. |
ConfigUpdaterListener |
getListener()
Returns the listener to inform about progress. |
static void |
main(java.lang.String[] args)
Creates a new configuration file or updates an existing one. |
void |
update(java.io.File baseDir)
Clears the source file list in the configuration (!) |
void |
update(java.util.List remoteFileList)
Clears the source file list in the configuration (!) |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ConfigUpdater()
public ConfigUpdater(ConfigUpdaterListener listener)
listener - Used for writing log messages - Cannot be null.
public ConfigUpdater(java.io.File configFile)
throws InvalidConfigException
configFile - Existing configuration file.
InvalidConfigException - Error parsing an existing configuration.
public ConfigUpdater(java.io.File configFile,
ConfigUpdaterListener listener)
throws InvalidConfigException
configFile - Existing configuration file.listener - Used for writing log messages.
InvalidConfigException - Error parsing an existing configuration.| Method Detail |
|---|
public final void update(java.util.List remoteFileList)
throws java.io.IOException
remoteFileList - List with RemoteFile objects.
java.io.IOException - Error while copying.
public final void update(java.io.File baseDir)
throws java.io.IOException
baseDir - Source directory to create a configuration for.
java.io.IOException - Error while copying.public final Config getConfig()
public final ConfigUpdaterListener getListener()
null.
public static void main(java.lang.String[] args)
throws InvalidConfigException,
java.io.IOException
args - First argument is the path and name of the configuration file.
Second argument is the directory to create the configuration
for.
InvalidConfigException - Error parsing an existing configuration file.
java.io.IOException - I/O-Error.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||