| CustomDNS.SimpleConfiguration CustomDNS.Configuration
Configuration | public class Configuration extends SimpleConfiguration (Code) | | A configuration manager used by several of our applications.
This class has been specialized for use with CustomDNS. It knows how to
parse our command-line arguments and act on the information in our
properties file.
|
Constructor Summary | |
public | Configuration(String connectionFile, String configFile) Create a Configuration object from the supplied files. |
Method Summary | |
public Connection | connectToDatabase() Create a JDBC Connection object. | public String | getConnectionFile() Get the name of the file with our e-speak connection information. | public static Configuration | parseArguments(String appname, String[] args) Parse our command line arguments and get our configuration.
If something goes wrong, this function will print an error message
on the application's behalf and exit promptly.
Parameters: appname - The name of the application (used to print errormessages). Parameters: args - Our command-line arguments. |
Configuration | public Configuration(String connectionFile, String configFile) throws FileNotFoundException, IOException(Code) | | Create a Configuration object from the supplied files.
Parameters: connectionFile - The property file describing our e-speakconnection. Parameters: configFile - The property file with our CustomDNSconfiguration. exception: FileNotFoundException - The specified property filedoesn't exist. exception: IOException - An error occured while reading from theproperty file. |
getConnectionFile | public String getConnectionFile()(Code) | | Get the name of the file with our e-speak connection information.
The name of the connection file we pass to ESConnection. |
parseArguments | public static Configuration parseArguments(String appname, String[] args)(Code) | | Parse our command line arguments and get our configuration.
If something goes wrong, this function will print an error message
on the application's behalf and exit promptly.
Parameters: appname - The name of the application (used to print errormessages). Parameters: args - Our command-line arguments. These should be an espeakconnection properties file and customdns.prop. A Configuration object. |
|
|