Cantera  2.0
Public Member Functions | Protected Attributes | List of all members
XML_NoChild Class Reference

Class representing a specific type of XML file formatting error. More...

Inheritance diagram for XML_NoChild:
[legend]
Collaboration diagram for XML_NoChild:
[legend]

Public Member Functions

 XML_NoChild (const XML_Node *p, std::string parent, std::string child, int line=0)
 Constructor.
 
virtual ~XML_NoChild () throw ()
 Destructor.
 
const char * what () const throw ()
 Get a description of the error.
 
void save ()
 Function to put this error onto Cantera's error stack.
 
virtual std::string getMessage () const
 Method overridden by derived classes to formatted the error message.
 
virtual std::string getClass () const
 Method overridden by derived classes to indicate their type.
 

Protected Attributes

int m_line
 Line number of the file.
 
std::string m_msg
 String message for the error.
 
std::string procedure_
 The name of the procedure where the exception occurred.
 

Detailed Description

Class representing a specific type of XML file formatting error.

An XML_Node doesn't have a required child node

Definition at line 93 of file xml.cpp.

Constructor & Destructor Documentation

XML_NoChild ( const XML_Node p,
std::string  parent,
std::string  child,
int  line = 0 
)
inline

Constructor.

An XML element doesn't have the required child node

Parameters
pXML_Node to write a string error message
parentNamf of the parent node
childName of the required child node
lineLine number where the error occurred.

Definition at line 106 of file xml.cpp.

References Cantera::setError(), and XML_Node::write().

virtual ~XML_NoChild ( ) throw ()
inlinevirtual

Destructor.

Definition at line 122 of file xml.cpp.

Member Function Documentation

const char * what ( ) const throw ()
inherited
void save ( )
inherited
std::string getMessage ( ) const
virtualinherited

Method overridden by derived classes to formatted the error message.

Reimplemented in IndexError, and ArraySizeError.

Definition at line 56 of file ctexceptions.cpp.

References CanteraError::msg_.

Referenced by CanteraError::save(), and CanteraError::what().

virtual std::string getClass ( ) const
inlinevirtualinherited

Method overridden by derived classes to indicate their type.

Reimplemented in IndexError, and ArraySizeError.

Definition at line 97 of file ctexceptions.h.

Referenced by CanteraError::what().

Member Data Documentation

int m_line
protectedinherited

Line number of the file.

Definition at line 56 of file xml.cpp.

std::string m_msg
protectedinherited

String message for the error.

Definition at line 59 of file xml.cpp.

std::string procedure_
protectedinherited

The name of the procedure where the exception occurred.

Definition at line 107 of file ctexceptions.h.

Referenced by CanteraError::save(), and CanteraError::what().


The documentation for this class was generated from the following file: