DEIMOS
Earth Observation Mission CFI Software
FileHandlling Software User Manual
ESA

EECFI::XmlFile Class Reference

Class for reading and writing XML files. More...

Inheritance diagram for EECFI::XmlFile:
EECFI::CfiClass

List of all members.

Public Member Functions

 XmlFile ()
 Empty constructor.
 XmlFile (string fileNam) throw (CfiError)
 Construct object and init parser.
 ~XmlFile () throw (CfiError)
 Class destructor.
void create () throw (CfiError)
 Create an XML tree in memory.
void read (const string fileNam) throw (CfiError)
 Read file from disk.
void write () throw (CfiError)
 Write file to disk.
void write (const string fileNam) throw (CfiError)
 Write file to disk with different name.
void clean () throw (CfiError)
 Clean memory.
void root () throw (CfiError)
 Go to root element.
void next () throw (CfiError)
 Go to next element.
void nextSibling () const
 Go to the next Sibling.
void toElement (const string element) throw (CfiError)
 Go to element.
void toPath (const string path) throw (CfiError)
 Go to path.
string currentElementName () throw (CfiError)
 Get current element name.
string currentPathName () throw (CfiError)
 Get current path name.
string getElementValueAsString (const string element) throw (CfiError)
 Read element value as a string.
long getElementValueAsInt (const string element) throw (CfiError)
 Read element value as an integer.
double getElementValueAsReal (const string element) throw (CfiError)
 Read element value as a real number.
vector< string > & getElementArrayAsString (const string element, vector< string > &outVector) throw (CfiError)
 Read array of values as strings.
vector< long > & getElementArrayAsInt (const string element, vector< long > &outVector) throw (CfiError)
 Read array of values as integers.
vector< double > & getElementArrayAsReal (const string element, vector< double > &outVector) throw (CfiError)
 Read array of values as real numbers.
string getAttributeValueAsString (const string element, const string attribute) throw (CfiError)
 Read attribute value as a string.
long getAttributeValueAsInt (const string element, const string attribute) throw (CfiError)
 Read attribute value as an integer.
double getAttributeValueAsReal (const string element, const string attribute) throw (CfiError)
 Read attribute value as a real number.
string getPathValueAsString (const string path) throw (CfiError)
 Read path node value as a string.
long getPathValueAsInt (const string path) throw (CfiError)
 Read path node value as an integer.
double getPathValueAsReal (const string path) throw (CfiError)
 Read path node value as a real number.
vector< string > & getPathArrayAsString (const string node, vector< string > &outVector) throw (CfiError)
 Read string node array.
vector< long > & getPathArrayAsInt (const string node, vector< long > &outVector) throw (CfiError)
 Read integer node array.
vector< double > & getPathArrayAsReal (const string node, vector< double > &outVector) throw (CfiError)
 Read double node array.
void createRoot (const string element) throw (CfiError)
 Create root element.
void addChild (const string parent, const string child) throw (CfiError)
 Add child element.
void addNext (const string current, const string next) throw (CfiError)
 Append sibling element after current one.
void addPrevious (const string current, const string previous) throw (CfiError)
 Insert sibling element before current one.
void addAttribute (const string element, const string attribute) throw (CfiError)
 Add attribute.
void copyNode (const string destPath, const string sourceXmlFile, const string sourcePath) throw (CfiError)
 Copy a node of one XmlFile to parent node in this XmlFile.
void removeNode (const string path) throw (CfiError)
 Remove node.
void setValue (const string path, const string value, const string format) throw (CfiError)
 Set string node value with format.
void setValue (const string path, const long value, const string format) throw (CfiError)
 Set integer node value with format.
void setValue (const string path, const double value, const string format) throw (CfiError)
 Set real node value with format.
void addChild (const string parent, const string child, const string value, const string format) throw (CfiError)
 Add a child element with a string value.
void addChild (const string parent, const string child, const long value, const string format) throw (CfiError)
 Add a child element with an integer value.
void addChild (const string parent, const string child, const double value, const string format) throw (CfiError)
 Add a child element with a real value.
void addNext (const string current, const string next, const string value, const string format) throw (CfiError)
 Append an element after the current one with a string value.
void addNext (const string current, const string next, const long value, const string format) throw (CfiError)
 Append an element after the current one with an integer value.
void addNext (const string current, const string next, const double value, const string format) throw (CfiError)
 Append an element after the current one with a real value.
void addPrevious (const string current, const string previous, const string value, const string format) throw (CfiError)
 Insert an element before the current one with a string value.
void addPrevious (const string current, const string previous, const long value, const string format) throw (CfiError)
 Insert an element before the current one with an integer value.
void addPrevious (const string current, const string previous, const double value, const string format) throw (CfiError)
 Insert an element before the current one with a real value.
void addAttribute (const string element, const string attribute, const string value, const string format) throw (CfiError)
 Add attribute with a string value to an element.
void addAttribute (const string element, const string attribute, const long value, const string format) throw (CfiError)
 Add attribute with an integer value to an element.
void addAttribute (const string element, const string attribute, const double value, const string format) throw (CfiError)
 Add attribute with a real value to an element.
string findValueInElement (const string element, const string value) throw (CfiError)
 Find element with value.
string findValueInPath (const string path, const string value) throw (CfiError)
 Find node with value.
void createHeader (long fileExtensionType) throw (CfiError)
 Creates a blank header.
void createHeader (FixedHeader &xmlHeader) throw (CfiError)
 Creates a fixed header with the input values.
string createFileName (long satelliteId, string fileClass, string fileType, string instanceId, long fileExtensionType) throw (CfiError)
 Generates a complete Cryosat file name.
FileNameItems getFileNameItems (string fileNam) throw (CfiError)
 Retrieve items of created fileName.
void setFixedHeaderItem (const string itemName, const string itemValue) throw (CfiError)
 Set an item in the fixed header.
void setFixedHeaderItems (const string fileNam, const string fileDescription, const string notes, const string mission, const string fileClass, const string filetype, const string validityStart, const string validityStop, const long fileVersion, const string system, const string creator, const string creatorVersion, const string creationDate) throw (CfiError)
 Set all items in the fixed header.
string getFixedHeaderItem (const string itemName) throw (CfiError)
 Get an item from the fixed header.
FixedHeader getFixedHeader () throw (CfiError)
 Get fixed header data.
long getId () const
 Get id.
string getFileName () const
 Get fileName.
void setSchema (const string schemaName, bool setAll)
 Set schema name.
void removeSchema (bool removeAll)
 Remove schema name.
vector< string > & getStringValuesFromList (const string listPath, const string element, vector< string > &outVector) throw (CfiError)
 Read elements from a list.

Detailed Description

Class for reading and writing XML files.

This class is used for reading and writing XML files according to the Earth Explorer Mission File Format Guidelines

It relies on the EO_FILE_HANDLING CFI software and the GNOME libxml2 (http://xmlsoft.org)

In memory representation of the XML file is maintained in the form of a tree. Navigation through the tree is performed with the help of a pointer. The following methods can be used for moving the pointer:

The current position can be retrieved using the following methods:

Methods for creating nodes, reading and writing node values will move the pointer to the requested element if the execution is successful.


Constructor & Destructor Documentation

EECFI::XmlFile::XmlFile (  ) 

Empty constructor.

EECFI::XmlFile::XmlFile ( string  fileNam  )  throw (CfiError)

Construct object and init parser.

Parameters:
fileNam Name of the file.
EECFI::XmlFile::~XmlFile (  )  throw (CfiError)

Class destructor.


Member Function Documentation

void EECFI::XmlFile::addAttribute ( const string  element,
const string  attribute 
) throw (CfiError)

Add attribute.

Parameters:
element XPath expression of element node to which the new attribute is added.
attribute Attribute name.

The tree pointer is set to the element that contains the attribute.

void EECFI::XmlFile::addAttribute ( const string  element,
const string  attribute,
const string  value,
const string  format 
) throw (CfiError)

Add attribute with a string value to an element.

Parameters:
element XPath expression of element node to which the new attribute is added.
attribute Inserted attribute name.
value Attribute value.
format Value format as expressed for printf functions. If format is empty "%%s" is used.

The tree pointer is set to element that owns the attribute.

void EECFI::XmlFile::addAttribute ( const string  element,
const string  attribute,
const long  value,
const string  format 
) throw (CfiError)

Add attribute with an integer value to an element.

Parameters:
element XPath expression of element node to which the new attribute is added.
attribute Inserted attribute name.
value Attribute value.
format Value format as expressed for printf functions. If format is empty "%%s" is used.

The tree pointer is set to element that owns the attribute.

void EECFI::XmlFile::addAttribute ( const string  element,
const string  attribute,
const double  value,
const string  format 
) throw (CfiError)

Add attribute with a real value to an element.

Parameters:
element XPath expression of element node to which the new attribute is added.
attribute Inserted attribute name.
value Attribute value.
format Value format as expressed for printf functions. If format is empty "%%s" is used.

The tree pointer is set to element that owns the attribute.

void EECFI::XmlFile::addChild ( const string  parent,
const string  child,
const string  value,
const string  format 
) throw (CfiError)

Add a child element with a string value.

Parameters:
parent XPath expression of element node to which the child is added.
child Child element name.
value Element value.
format Value format as expressed for printf functions. If format is empty "%%s" is used.

The tree pointer is set to the created element.

void EECFI::XmlFile::addChild ( const string  parent,
const string  child,
const long  value,
const string  format 
) throw (CfiError)

Add a child element with an integer value.

Parameters:
parent XPath expression of element node to which the child is added.
child Child element name.
value Element value.
format Value format as expressed for printf functions. If format is empty "%%s" is used.

The tree pointer is set to the created element.

void EECFI::XmlFile::addChild ( const string  parent,
const string  child 
) throw (CfiError)

Add child element.

Parameters:
parent XPath expression of element node to which the child is added.
child Child element name.

The tree pointer is set to the created element.

void EECFI::XmlFile::addChild ( const string  parent,
const string  child,
const double  value,
const string  format 
) throw (CfiError)

Add a child element with a real value.

Parameters:
parent XPath expression of element node to which the child is added.
child Child element name.
value Element value.
format Value format as expressed for printf functions. If format is empty "%%s" is used.

The tree pointer is set to the created element.

void EECFI::XmlFile::addNext ( const string  current,
const string  next,
const string  value,
const string  format 
) throw (CfiError)

Append an element after the current one with a string value.

Parameters:
current XPath expression of element node to which the new element is appended.
next Appended element name.
value Element value.
format Value format as expressed for printf functions. If format is empty "%%s" is used.

The tree pointer is set to the created element.

void EECFI::XmlFile::addNext ( const string  current,
const string  next,
const long  value,
const string  format 
) throw (CfiError)

Append an element after the current one with an integer value.

Parameters:
current XPath expression of element node to which the new element is appended.
next Appended element name.
value Element value.
format Value format as expressed for printf functions. If format is empty "%%s" is used.

The tree pointer is set to the created element.

void EECFI::XmlFile::addNext ( const string  current,
const string  next,
const double  value,
const string  format 
) throw (CfiError)

Append an element after the current one with a real value.

Parameters:
current XPath expression of element node to which the new element is appended.
next Appended element name.
value Element value.
format Value format as expressed for printf functions. If format is empty "%%s" is used.

The tree pointer is set to the created element.

void EECFI::XmlFile::addNext ( const string  current,
const string  next 
) throw (CfiError)

Append sibling element after current one.

Parameters:
current XPath expression of element node to which the new element is appended.
next Appended element name.

The tree pointer is set to the created element.

void EECFI::XmlFile::addPrevious ( const string  current,
const string  previous,
const long  value,
const string  format 
) throw (CfiError)

Insert an element before the current one with an integer value.

Parameters:
current XPath expression of element node in front of which the new element is appended.
previous Inserted element name.
value Element value.
format Value format as expressed for printf functions. If format is empty "%%s" is used.

The tree pointer is set to the created element.

void EECFI::XmlFile::addPrevious ( const string  current,
const string  previous,
const string  value,
const string  format 
) throw (CfiError)

Insert an element before the current one with a string value.

Parameters:
current XPath expression of element node in front of which the new element is appended.
previous Inserted element name.
value Element value.
format Value format as expressed for printf functions. If format is empty "%%s" is used.

The tree pointer is set to the created element.

void EECFI::XmlFile::addPrevious ( const string  current,
const string  previous,
const double  value,
const string  format 
) throw (CfiError)

Insert an element before the current one with a real value.

Parameters:
current XPath expression of element node in front of which the new element is appended.
previous Inserted element name.
value Element value.
format Value format as expressed for printf functions. If format is empty "%%s" is used.

The tree pointer is set to the created element.

void EECFI::XmlFile::addPrevious ( const string  current,
const string  previous 
) throw (CfiError)

Insert sibling element before current one.

Parameters:
current XPath expression of element node in front of which the new element is inserted.
previous Inserted element name.

The tree pointer is set to the created element.

void EECFI::XmlFile::clean (  )  throw (CfiError)

Clean memory.

void EECFI::XmlFile::copyNode ( const string  destPath,
const string  sourceXmlFile,
const string  sourcePath 
) throw (CfiError)

Copy a node of one XmlFile to parent node in this XmlFile.

Parameters:
destPath XPath expression of element node to which the new element will be added.
sourceXmlFile File Xml Source, some elements will be added to the destination file.
sourcePath XPath expression of element node is copied to destination file, this element is child in destPath.

Two files, one file is a destination file and another file is source file, elements of the source files will be copied into destination files. To have it, there are two tree pointer.

void EECFI::XmlFile::create (  )  throw (CfiError)

Create an XML tree in memory.

string EECFI::XmlFile::createFileName ( long  missionId,
string  fileClass,
string  fileType,
string  instanceId,
long  fileExtensionType 
) throw (CfiError)

Generates a complete Cryosat file name.

Parameters:
missionId Satellite Id (one of SatIdEnum).
fileClass Type of activity for which the file is used.
fileType File type.
instanceId Makes the file unique.
fileExtensionType Type of XML file to add header.
Returns:
File name generated.
void EECFI::XmlFile::createHeader ( FixedHeader fixedHeader  )  throw (CfiError)

Creates a fixed header with the input values.

Parameters:
fixedHeader FixedHeader object containing data for the fixed header.

Sets the value of all Fixed Header elements.

void EECFI::XmlFile::createHeader ( long  fileExtensionType  )  throw (CfiError)

Creates a blank header.

Parameters:
fileExtensionType Type of XML. Should be one of the possibles values in FileExtensionTypeEnum.

Generates a new blank Header including both Fixed and Variable headers.

void EECFI::XmlFile::createRoot ( const string  element  )  throw (CfiError)

Create root element.

Parameters:
element Root element name.
string EECFI::XmlFile::currentElementName (  )  throw (CfiError)

Get current element name.

Returns:
Current element name
string EECFI::XmlFile::currentPathName (  )  throw (CfiError)

Get current path name.

Returns:
Current XPath node name
string EECFI::XmlFile::findValueInElement ( const string  element,
const string  value 
) throw (CfiError)

Find element with value.

Parameters:
element Element name.
value Element value.
Returns:
XPath name of the found element.

Find the first occurence of the element whose name and value match the requested input parameters and return its absolute XPath name.

string EECFI::XmlFile::findValueInPath ( const string  path,
const string  value 
) throw (CfiError)

Find node with value.

Parameters:
path XPath expression of node name (wildcard allowed).
value Element value.
Returns:
XPath name of the found element.

Find the first occurence of the element whose XPath name and value match the requested input parameters and return its absolute XPath name. The input XPath name can contain a "*" wildcard for searching through sequences.

long EECFI::XmlFile::getAttributeValueAsInt ( const string  element,
const string  attribute 
) throw (CfiError)

Read attribute value as an integer.

Parameters:
element Element name.
attribute Attribute name.
Returns:
Attribute value.

Return the value of the given attribute in the first occurence of the given element from the current position as integer. If the current position is an element whose name equals "element", returns the value of the given attribute in the current element. The tree pointer is set to the found element.

double EECFI::XmlFile::getAttributeValueAsReal ( const string  element,
const string  attribute 
) throw (CfiError)

Read attribute value as a real number.

Parameters:
element Element name.
attribute Attribute name.
Returns:
Attribute value.

Return the value of the given attribute in the first occurence of the given element from the current position as double. If the current position is an element whose name equals "element", returns the value of the given attribute in the current element. The tree pointer is set to the found element.

string EECFI::XmlFile::getAttributeValueAsString ( const string  element,
const string  attribute 
) throw (CfiError)

Read attribute value as a string.

Parameters:
element Element name.
attribute Attribute name.
Returns:
Attribute value.

Return the value of the given attribute in the first occurence of the given element from the current position as string. If the current position is an element whose name equals "element", returns the value of the given attribute in the current element. The tree pointer is set to the found element.

vector< long > & EECFI::XmlFile::getElementArrayAsInt ( const string  element,
vector< long > &  outVector 
) throw (CfiError)

Read array of values as integers.

Parameters:
element Element name.
outVector Vector of element values.

Return a vector with the values of all ocurrences of the given element as integers. The tree pointer is set to the last found element.

vector< double > & EECFI::XmlFile::getElementArrayAsReal ( const string  element,
vector< double > &  outVector 
) throw (CfiError)

Read array of values as real numbers.

Parameters:
element Element name.
outVector Vector of element values.

Return a vector with the values of all ocurrences of the given element as doubles. The tree pointer is set to the last found element.

vector< string > & EECFI::XmlFile::getElementArrayAsString ( const string  element,
vector< string > &  outVector 
) throw (CfiError)

Read array of values as strings.

Parameters:
element Element name.
outVector Vector of element values.

Return a vector with the values of all ocurrences of the given element as strings. The tree pointer is set to the last found element.

long EECFI::XmlFile::getElementValueAsInt ( const string  element  )  throw (CfiError)

Read element value as an integer.

Parameters:
element Element name.
Returns:
Element value.

Return the value of the first occurence after the current position of the given element as integer. The tree pointer is set to the found element.

double EECFI::XmlFile::getElementValueAsReal ( const string  element  )  throw (CfiError)

Read element value as a real number.

Parameters:
element Element name.
Returns:
Element value.

Return the value of the first occurence after the current position of the given element as double. The tree pointer is set to the found element.

string EECFI::XmlFile::getElementValueAsString ( const string  element  )  throw (CfiError)

Read element value as a string.

Parameters:
element Element name.
Returns:
Element value.

Return the value of the first occurence after the current position of the given element as string. The tree pointer is set to the found element.

string EECFI::XmlFile::getFileName (  )  const

Get fileName.

Returns:
Value of internal attribute fileName.
FileNameItems EECFI::XmlFile::getFileNameItems ( string  fileNam  )  throw (CfiError)

Retrieve items of created fileName.

Parameters:
fileNam File Name.
FixedHeader EECFI::XmlFile::getFixedHeader (  )  throw (CfiError)

Get fixed header data.

Returns:
FixedHeader object with all the values of the Fixed Header of the file.

Gets the value of all Fixed Header elements.

string EECFI::XmlFile::getFixedHeaderItem ( const string  itemName  )  throw (CfiError)

Get an item from the fixed header.

Parameters:
itemName Name of the element which value we want to retrieve.
Returns:
Value of the node of name itemName.

This function gets the value of a Fixed Header node.

long EECFI::XmlFile::getId (  )  const

Get id.

Returns:
Value of internal attribute id.

Referenced by nextSibling().

vector< long > & EECFI::XmlFile::getPathArrayAsInt ( const string  path,
vector< long > &  outVector 
) throw (CfiError)

Read integer node array.

Parameters:
path Node XPath name.
outVector Vector of node values.

Returns an integer vector with the values of all ocurrences of the given path. This method should be used for reading values from sequences and therefore the path must be absolute and must include a "*" wildcard for indicating the repeated element. The tree pointer is set to the last found element.

vector< double > & EECFI::XmlFile::getPathArrayAsReal ( const string  path,
vector< double > &  outVector 
) throw (CfiError)

Read double node array.

Parameters:
path Node XPath name.
outVector Vector of node values.

Returns a double vector with the values of all ocurrences of the given path. This method should be used for reading values from sequences and therefore the path must be absolute and must include a "*" wildcard for indicating the repeated element. The tree pointer is set to the last found element.

vector< string > & EECFI::XmlFile::getPathArrayAsString ( const string  path,
vector< string > &  outVector 
) throw (CfiError)

Read string node array.

Parameters:
path Node XPath name.
outVector Vector of node values.

Returns a string vector with the values of all ocurrences of the given path. This method should be used for reading values from sequences and therefore the path must be absolute and must include a "*" wildcard for indicating the repeated element. The tree pointer is set to the last found element.

long EECFI::XmlFile::getPathValueAsInt ( const string  path  )  throw (CfiError)

Read path node value as an integer.

Parameters:
path XPath expression of node.
Returns:
Node value.

Return the value of the node with the given XPath name as integer. The XPath name can be either absolute or relative to the current element. The tree pointer will be set to the found element or the element that contains the found attribute.

double EECFI::XmlFile::getPathValueAsReal ( const string  path  )  throw (CfiError)

Read path node value as a real number.

Parameters:
path XPath expression of node.
Returns:
Node value.

Return the value of the node with the given XPath name as double. The XPath name can be either absolute or relative to the current element. The tree pointer will be set to the found element or the element that contains the found attribute.

string EECFI::XmlFile::getPathValueAsString ( const string  path  )  throw (CfiError)

Read path node value as a string.

Parameters:
path XPath expression of node.
Returns:
Node value.

Return the value of the node with the given XPath name as string. The XPath name can be either absolute or relative to the current element. The tree pointer will be set to the found element or the element that contains the found attribute.

vector< string > & EECFI::XmlFile::getStringValuesFromList ( const string  listPath,
const string  element,
vector< string > &  outVector 
) throw (CfiError)

Read elements from a list.

Parameters:
listPath Path of the list to read.
element Element to read.
outVector String vector with the values.
void EECFI::XmlFile::next (  )  throw (CfiError)

Go to next element.

Go to the next element. If the current element has a children then the next is first child else the next could be the next sibling, or the next element could be the next sibling of the parent if the next element has not sibling.

void EECFI::XmlFile::nextSibling (  )  const

Go to the next Sibling.

References getId().

void EECFI::XmlFile::read ( const string  fileNam  )  throw (CfiError)

Read file from disk.

void EECFI::XmlFile::removeNode ( const string  path  )  throw (CfiError)

Remove node.

Parameters:
path XPath name of the node to be removed.

Remove the requested node and all its descendants. The tree pointer is not moved.

void EECFI::XmlFile::removeSchema ( bool  removeAll  ) 

Remove schema name.

Parameters:
removeAll Indicates if schema and version will be removed (true) or only the schema (false).
void EECFI::XmlFile::root (  )  throw (CfiError)

Go to root element.

void EECFI::XmlFile::setFixedHeaderItem ( const string  itemName,
const string  itemValue 
) throw (CfiError)

Set an item in the fixed header.

Parameters:
itemName Name of the element which value we want to modify.
itemValue New value assigned for the node.

Sets the value of any element of a Header.

void EECFI::XmlFile::setFixedHeaderItems ( const string  fileNam,
const string  fileDescription,
const string  notes,
const string  mission,
const string  fileClass,
const string  fileType,
const string  validityStart,
const string  validityStop,
const long  fileVersion,
const string  system,
const string  creator,
const string  creatorVersion,
const string  creationDate 
) throw (CfiError)

Set all items in the fixed header.

Parameters:
fileNam Name of the file.
fileDescription Description of the file.
notes Notes about the file.
mission Mission the file belongs to.
fileClass File class.
fileType File type.
validityStart Date when the file starts being valid.
validityStop Date when the file stops being valid.
fileVersion Version of the file.
system System.
creator Creator name.
creatorVersion Version put by the creator.
creationDate Date of creation.

Sets the value of any element of a Header.

void EECFI::XmlFile::setSchema ( const string  schemaName,
bool  setAll 
)

Set schema name.

Parameters:
schemaName Name of the new schema.
setAll Indicates if schema and version will be changed (true) or only the schema (false).
void EECFI::XmlFile::setValue ( const string  path,
const double  value,
const string  format 
) throw (CfiError)

Set real node value with format.

Parameters:
path XPath name of node.
value New node value.
format Value format as expressed for printf functions. If format is empty "%%s" is used.

The tree pointer is set to the requested element. In case an attribute is requested it is set to the element that contains the attribute.

void EECFI::XmlFile::setValue ( const string  path,
const long  value,
const string  format 
) throw (CfiError)

Set integer node value with format.

Parameters:
path XPath name of node.
value New node value.
format Value format as expressed for printf functions. If format is empty "%%s" is used.

The tree pointer is set to the requested element. In case an attribute is requested it is set to the element that contains the attribute.

void EECFI::XmlFile::setValue ( const string  path,
const string  value,
const string  format 
) throw (CfiError)

Set string node value with format.

Parameters:
path XPath name of node.
value New node value.
format Value format as expressed for printf functions. If format is empty "%%s" is used.

The tree pointer is set to the requested element. In case an attribute is requested it is set to the element that contains the attribute.

void EECFI::XmlFile::toElement ( const string  element  )  throw (CfiError)

Go to element.

Parameters:
element Element name to be found.

Set the tree pointer to the first occurrence of the given element after the current position.

void EECFI::XmlFile::toPath ( const string  path  )  throw (CfiError)

Go to path.

Parameters:
path Path name to be found, either absolute or relative to the current element.

Set the tree pointer to the first occurence of the given path after the current position.

void EECFI::XmlFile::write (  )  throw (CfiError)

Write file to disk.

void EECFI::XmlFile::write ( const string  fileNam  )  throw (CfiError)

Write file to disk with different name.

Parameters:
fileNam Output file name.

Generated on Thu Jul 19 2012 15:36:26 for by doxygen 1.7.1