Main Page | Packages | Class Hierarchy | Class List | Directories | Class Members

IDVR.Tools.XMLParser Class Reference

#include <XMLParser.h>

List of all members.


Detailed Description

Class for loading and saving the application sttings into a XML-file.

This class is part of the Tools namespace and its task is the handling of the loading and saving of the application sttings.

To saving several application settings which are choosen by the user on the main GUI window (see class Neu) this class implements a XML parser which actually saves those setting in a predefined XML data structure. The file name and path will be choosen by the user by a standard file save dialog and is assigned to the main saving function XMLParser.save_ConfigFile.
Furthermore, the user has the possiblity to save a complete opacity and color transfer function which is been defined in the class TransferFuncWin. Like before, the file name and path will be assigned to the function XMLParser.save_Transferfunction which implements the saving of the transfer function into a XML data structure.

To load the application setting or the user-defined transferfunctions the member function XMLParser.load_ConfigFile and XMLParser.load_Transferfunction are included in this class.

See also:
Neu - the main GUI window class

TransferFuncWin - the transfer function editor class

Author:
Bernhard Pflugfelder
Version:
1.0
Date:
02-20-2005


Public Member Functions

 XMLParser (String *n_FilePath)
 Constructor initialization with the valid XML file name and path.
void load_ConfigFile (void)
 Loads the entire application settings from an already specified XML file.
Transferfunctionload_Transferfunction (void)
 Loads the entire opacity and color transfer function from an already specified XML file.
void save_ConfigFile (Array *n_NewValues)
 Saves the assigned values of the parameter into the already specified XML file.
void save_Transferfunction (Transferfunction *n_TransFunc)
 Saves the assigned transfer function into the already specified XML file.

Private Types

enum  attributes { NAME = 0, VALUE }
 Constant variables for xml attribute identification. More...
enum  colorIndices
 Constant n_Index values for the three color components red, green and blue.

Private Member Functions

void read_DatafileSettings (XmlNodeReader *n_XMLReader)
 Reads the values of teh setting group Datafile from the XML file.
void read_PhongShadingSettings (XmlNodeReader *n_XMLReader)
 Reads the values of teh setting group PhongShading from the XML file.
void read_OptimationSettings (XmlNodeReader *n_XMLReader)
 Reads the values of teh setting group Optimations from the XML file.
void read_DepthCueingSettings (XmlNodeReader *n_XMLReader)
 Reads the values of teh setting group DepthCueing from the XML file.
void read_MIPSettings (XmlNodeReader *n_XMLReader)
 Reads the values of teh setting group MIP from the XML file.
void read_ContourSettings (XmlNodeReader *n_XMLReader)
 Reads the values of teh setting group Contour from the XML file.
void read_ToneSettings (XmlNodeReader *n_XMLReader)
 Reads the values of teh setting group Tone from the XML file.
void save_DatafileSettings (XmlTextWriter *n_SaveConfigFile, Array *n_NewValues, int *n_Index)
 Saves the assigned values of the setting group Datafile into the specified XML file.
void save_PhongShadingSettings (XmlTextWriter *n_SaveConfigFile, Array *n_NewValues, int *n_Index)
 Saves the assigned values of the setting group PhongShading into the specified XML file.
void save_OptimationSettings (XmlTextWriter *n_SaveConfigFile, Array *n_NewValues, int *n_Index)
 Saves the assigned values of the setting group Optimations into the specified XML file.
void save_DepthCueingSettings (XmlTextWriter *n_SaveConfigFile, Array *n_NewValues, int *n_Index)
 Saves the assigned values of the setting group DeothCueing into the specified XML file.
void save_MIPSettings (XmlTextWriter *n_SaveConfigFile, Array *n_NewValues, int *n_Index)
 Saves the assigned values of the setting group MIP into the specified XML file.
void save_ContourSettings (XmlTextWriter *n_SaveConfigFile, Array *n_NewValues, int *n_Index)
 Saves the assigned values of the setting group Contour into the specified XML file.
void save_ToneSettings (XmlTextWriter *n_SaveConfigFile, Array *n_NewValues, int *n_Index)
 Saves the assigned values of the setting group Tone into the specified XML file.

Private Attributes

String * m_FilePath
 Saves the current file path of the XML file.
String * m_FileName
 Saves the current file name of the XML file.


Member Enumeration Documentation

enum IDVR::Tools::XMLParser::attributes [private]
 

Constant variables for xml attribute identification.

Enumeration values:
NAME  The constant value for xml attribute name.
VALUE  The constant value for xml attribute value.


Constructor & Destructor Documentation

XMLParser::XMLParser String *  n_FilePath  ) 
 

Constructor initialization with the valid XML file name and path.

All member variables will be set to the corresponding parameters.

Parameters:
n_FilePath the new file name and path of an existing XML file.


Member Function Documentation

void XMLParser::load_ConfigFile void   ) 
 

Loads the entire application settings from an already specified XML file.

Select the XML file by calling the constructor XMLParser(String*). Thus, a new instance of this class must be created if a new file nam and path is choosen.

Transferfunction * XMLParser::load_Transferfunction void   ) 
 

Loads the entire opacity and color transfer function from an already specified XML file.

Select the XML file by calling the constructor XMLParser(String*). Thus, a new instance of this class must be created if a new file nam and path is choosen.

Returns:
An instance of the class Transferfunction which contains the loaded copacity and color functions.

void XMLParser::read_ContourSettings XmlNodeReader *  n_XMLReader  )  [private]
 

Reads the values of teh setting group Contour from the XML file.

Parameters:
n_XMLReader is the acutal standard XML parser as an instance of the standard class XmlNodeReader.

void XMLParser::read_DatafileSettings XmlNodeReader *  n_XMLReader  )  [private]
 

Reads the values of teh setting group Datafile from the XML file.

Parameters:
n_XMLReader is the acutal standard XML parser as an instance of the standard class XmlNodeReader.

void XMLParser::read_DepthCueingSettings XmlNodeReader *  n_XMLReader  )  [private]
 

Reads the values of teh setting group DepthCueing from the XML file.

Parameters:
n_XMLReader is the acutal standard XML parser as an instance of the standard class XmlNodeReader.

void XMLParser::read_MIPSettings XmlNodeReader *  n_XMLReader  )  [private]
 

Reads the values of teh setting group MIP from the XML file.

Parameters:
n_XMLReader is the acutal standard XML parser as an instance of the standard class XmlNodeReader.

void XMLParser::read_OptimationSettings XmlNodeReader *  n_XMLReader  )  [private]
 

Reads the values of teh setting group Optimations from the XML file.

Parameters:
n_XMLReader is the acutal standard XML parser as an instance of the standard class XmlNodeReader.

void XMLParser::read_PhongShadingSettings XmlNodeReader *  n_XMLReader  )  [private]
 

Reads the values of teh setting group PhongShading from the XML file.

Parameters:
n_XMLReader is the acutal standard XML parser as an instance of the standard class XmlNodeReader.

void XMLParser::read_ToneSettings XmlNodeReader *  n_XMLReader  )  [private]
 

Reads the values of teh setting group Tone from the XML file.

Parameters:
n_XMLReader is the acutal standard XML parser as an instance of the standard class XmlNodeReader.

void XMLParser::save_ConfigFile Array *  n_NewValues  ) 
 

Saves the assigned values of the parameter into the already specified XML file.

Select the XML file by calling the constructor XMLParser(String*). Thus, a new instance of this class must be created if a new file nam and path is choosen.

Parameters:
n_NewValues contains all needed application settings.

void XMLParser::save_ContourSettings XmlTextWriter *  n_SaveConfigFile,
Array *  n_NewValues,
int *  n_Index
[private]
 

Saves the assigned values of the setting group Contour into the specified XML file.

Parameters:
n_SaveConfigFile is the actual XML parser which creates a valid XML data structure.
n_NewValues contains the setting values.
n_Index is the current XML node number.

void XMLParser::save_DatafileSettings XmlTextWriter *  n_SaveConfigFile,
Array *  n_NewValues,
int *  n_Index
[private]
 

Saves the assigned values of the setting group Datafile into the specified XML file.

Parameters:
n_SaveConfigFile is the actual XML parser which creates a valid XML data structure.
n_NewValues contains the setting values.
n_Index is the current XML node number.

void XMLParser::save_DepthCueingSettings XmlTextWriter *  n_SaveConfigFile,
Array *  n_NewValues,
int *  n_Index
[private]
 

Saves the assigned values of the setting group DeothCueing into the specified XML file.

Parameters:
n_SaveConfigFile is the actual XML parser which creates a valid XML data structure.
n_NewValues contains the setting values.
n_Index is the current XML node number.

void XMLParser::save_MIPSettings XmlTextWriter *  n_SaveConfigFile,
Array *  n_NewValues,
int *  n_Index
[private]
 

Saves the assigned values of the setting group MIP into the specified XML file.

Parameters:
n_SaveConfigFile is the actual XML parser which creates a valid XML data structure.
n_NewValues contains the setting values.
n_Index is the current XML node number.

void XMLParser::save_OptimationSettings XmlTextWriter *  n_SaveConfigFile,
Array *  n_NewValues,
int *  n_Index
[private]
 

Saves the assigned values of the setting group Optimations into the specified XML file.

Parameters:
n_SaveConfigFile is the actual XML parser which creates a valid XML data structure.
n_NewValues contains the setting values.
n_Index is the current XML node number.

void XMLParser::save_PhongShadingSettings XmlTextWriter *  n_SaveConfigFile,
Array *  n_NewValues,
int *  n_Index
[private]
 

Saves the assigned values of the setting group PhongShading into the specified XML file.

Parameters:
n_SaveConfigFile is the actual XML parser which creates a valid XML data structure.
n_NewValues contains the setting values.
n_Index is the current XML node number.

void XMLParser::save_ToneSettings XmlTextWriter *  n_SaveConfigFile,
Array *  n_NewValues,
int *  n_Index
[private]
 

Saves the assigned values of the setting group Tone into the specified XML file.

Parameters:
n_SaveConfigFile is the actual XML parser which creates a valid XML data structure.
n_NewValues contains the setting values.
n_Index is the current XML node number.

void XMLParser::save_Transferfunction Transferfunction n_TransFunc  ) 
 

Saves the assigned transfer function into the already specified XML file.

Select the XML file by calling the constructor XMLParser(String*). Thus, a new instance of this class must be created if a new file nam and path is choosen.

Parameters:
n_TransFunc contains the opacity and color transfer functions.


The documentation for this class was generated from the following files:
Generated on Sat Apr 9 11:51:00 2005 for RayCaster wiht Importance Driven Volume Rendering (IDVR) by  doxygen 1.4.1