Geant4  10.02.p03
G4GDMLErrorHandler Class Reference

#include <G4GDMLRead.hh>

Inheritance diagram for G4GDMLErrorHandler:
Collaboration diagram for G4GDMLErrorHandler:

Public Member Functions

 G4GDMLErrorHandler (const G4bool set)
 
void warning (const xercesc::SAXParseException &exception)
 
void error (const xercesc::SAXParseException &exception)
 
void fatalError (const xercesc::SAXParseException &exception)
 
void resetErrors ()
 

Private Attributes

G4bool Suppress
 

Detailed Description

Definition at line 56 of file G4GDMLRead.hh.

Constructor & Destructor Documentation

◆ G4GDMLErrorHandler()

G4GDMLErrorHandler::G4GDMLErrorHandler ( const G4bool  set)
inline

Definition at line 62 of file G4GDMLRead.hh.

62 { Suppress = set; }

Member Function Documentation

◆ error()

void G4GDMLErrorHandler::error ( const xercesc::SAXParseException &  exception)
inline

Definition at line 73 of file G4GDMLRead.hh.

74  {
75  if (Suppress) { return; }
76  char* message = xercesc::XMLString::transcode(exception.getMessage());
77  G4cout << "G4GDML: VALIDATION ERROR! " << message
78  << " at line: " << exception.getLineNumber() << G4endl;
79  xercesc::XMLString::release(&message);
80  }
G4GLOB_DLL std::ostream G4cout
#define G4endl
Definition: G4ios.hh:61
Here is the caller graph for this function:

◆ fatalError()

void G4GDMLErrorHandler::fatalError ( const xercesc::SAXParseException &  exception)
inline

Definition at line 82 of file G4GDMLRead.hh.

83  {
84  error(exception);
85  }
void error(const xercesc::SAXParseException &exception)
Definition: G4GDMLRead.hh:73
Here is the call graph for this function:

◆ resetErrors()

void G4GDMLErrorHandler::resetErrors ( )
inline

Definition at line 86 of file G4GDMLRead.hh.

86 {}

◆ warning()

void G4GDMLErrorHandler::warning ( const xercesc::SAXParseException &  exception)
inline

Definition at line 64 of file G4GDMLRead.hh.

65  {
66  if (Suppress) { return; }
67  char* message = xercesc::XMLString::transcode(exception.getMessage());
68  G4cout << "G4GDML: VALIDATION WARNING! " << message
69  << " at line: " << exception.getLineNumber() << G4endl;
70  xercesc::XMLString::release(&message);
71  }
G4GLOB_DLL std::ostream G4cout
#define G4endl
Definition: G4ios.hh:61

Member Data Documentation

◆ Suppress

G4bool G4GDMLErrorHandler::Suppress
private

Definition at line 58 of file G4GDMLRead.hh.


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