OpenMW
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Public Member Functions | Private Member Functions | Private Attributes | List of all members
Compiler::StreamErrorHandler Class Reference

Error handler implementation: Write errors into stream. More...

#include <streamerrorhandler.hpp>

Inheritance diagram for Compiler::StreamErrorHandler:
Collaboration diagram for Compiler::StreamErrorHandler:

Public Member Functions

 StreamErrorHandler (std::ostream &ErrorStream)
 constructor More...
 
- Public Member Functions inherited from Compiler::ErrorHandler
 ErrorHandler ()
 constructor More...
 
virtual ~ErrorHandler ()
 destructor More...
 
bool isGood () const
 Was compiling successful? More...
 
int countErrors () const
 Return number of errors. More...
 
int countWarnings () const
 Return number of warnings. More...
 
void warning (const std::string &message, const TokenLoc &loc)
 Generate a warning message. More...
 
void error (const std::string &message, const TokenLoc &loc)
 Generate an error message. More...
 
void endOfFile ()
 Generate an error message for an unexpected EOF. More...
 
virtual void reset ()
 Remove all previous error/warning events. More...
 
void setWarningsMode (int mode)
 // 0 ignore, 1 rate as warning, 2 rate as error More...
 
void downgradeErrors (bool downgrade)
 Treat errors as warnings. More...
 

Private Member Functions

 StreamErrorHandler (const StreamErrorHandler &)
 
StreamErrorHandleroperator= (const StreamErrorHandler &)
 
virtual void report (const std::string &message, const TokenLoc &loc, Type type)
 Report error to the user. More...
 
virtual void report (const std::string &message, Type type)
 Report a file related error. More...
 

Private Attributes

std::ostream & mStream
 

Additional Inherited Members

- Protected Types inherited from Compiler::ErrorHandler
enum  Type { WarningMessage, ErrorMessage }
 

Detailed Description

Error handler implementation: Write errors into stream.

Constructor & Destructor Documentation

Compiler::StreamErrorHandler::StreamErrorHandler ( const StreamErrorHandler )
private
Compiler::StreamErrorHandler::StreamErrorHandler ( std::ostream &  ErrorStream)

constructor

Member Function Documentation

StreamErrorHandler& Compiler::StreamErrorHandler::operator= ( const StreamErrorHandler )
private
void Compiler::StreamErrorHandler::report ( const std::string &  message,
const TokenLoc loc,
Type  type 
)
privatevirtual

Report error to the user.

Implements Compiler::ErrorHandler.

void Compiler::StreamErrorHandler::report ( const std::string &  message,
Type  type 
)
privatevirtual

Report a file related error.

Implements Compiler::ErrorHandler.

Member Data Documentation

std::ostream& Compiler::StreamErrorHandler::mStream
private

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