|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--bill.util.config.Configuration | +--bill.util.config.gui.ConConfiguration
This class extends the standard Configuration class to provide some GUI specific functionality.
Fields inherited from class bill.util.config.Configuration |
_currentSection, _fileName, _sectionNames, _sections, ENTRY_CONFLICT_APPEND, ENTRY_CONFLICT_DISCARD, ENTRY_CONFLICT_OVERWRITE, SECTION_CONFLICT_APPEND, SECTION_CONFLICT_DISCARD, SECTION_CONFLICT_INCLUDE, SECTION_CONFLICT_OVERWRITE |
Constructor Summary | |
ConConfiguration(String fileName,
ConfigurationGUI gui)
Class creator. |
Method Summary | |
void |
addAFile(String logicalName,
String physicalName)
Add the specified configuration file to the list of defined configuration files. |
String |
getFileLocation(String logicalName)
Determines the location (directory and file name) for the specified logical file. |
Vector |
getFileNames()
Creates a list of all logical names of the configuration files contained in the current project configuration file. |
boolean |
isModified()
Checks to see if the configuration data defined has been modified since it's last saved. |
void |
removeAFile(String logicalName,
String physicalName)
Remove the specified configuration file from the list of defined configuration files. |
boolean |
save(String fileName)
Method to save the configuration back to a file. |
void |
setModified(boolean modified)
Sets the modification indicator as indicated. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public ConConfiguration(String fileName, ConfigurationGUI gui) throws FileNotFoundException, IOException, ConfigurationException
fileName
- Name of the configuration file to process.gui
- The ConfigurationGUI instance that is creating us. Used during
the save process to determine the individual project configuration files
that we need to save. For the project configuration file this has a value,
but for the project's individual configuration files it is null
.FileNotFoundException
- Indicates the file name passed in does
not exist or cannot be accessed.IOException
- File was found but an error occurred while reading it.ConfigurationException
- A processing error was encountered while
reading the configuration file, typically a syntax error.Method Detail |
public Vector getFileNames()
public void addAFile(String logicalName, String physicalName) throws ConfigurationException
logicalName
- The logical name of the configuration file to be addedphysicalName
- The physical name of the configuration file to be
added.public void removeAFile(String logicalName, String physicalName)
logicalName
- The logical name of the configuration file to be
removedphysicalName
- The physical name of the configuration file to be
removed.public String getFileLocation(String logicalName)
logicalName
- The logical file name to find the location forpublic boolean isModified()
true
if the data has been modified, false
otherwise.public void setModified(boolean modified)
modified
- The value to set the modification indicator to.public boolean save(String fileName)
fileName
- File name to save the configuration file under.true
if the save is successful, false
otherwise.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |