xCeption Class Reference

Exception class used in SmartWin. More...

Inherits exception.

List of all members.

Public Member Functions

virtual DWORD getErrorCode () const
 call from Windows API called in the Constructor
virtual const char * what () const throw ()
 Returns a descriptive error message explaining what went wrong.
virtual const TCHAR * whatWndMsg () const
 Returns a descriptive windows error message explaining what went wrong.
 xCeption (const SmartUtil::tstring &err) throw ()
 Overloaded Constructor basically doing the same as the const TCHAR * version.
 xCeption (const TCHAR *err) throw ()
 Constructor taking a const char pointer.


Detailed Description

Exception class used in SmartWin.

All exceptions thrown by SmartWin will be either of this class or derived from this class.
You should derive from this class yourself if you throw exceptions inside your event handlers.
Otherwise SmartWin may not be able to respond correctly to the Exception.


Constructor & Destructor Documentation

xCeption ( const TCHAR *  err  )  throw ()

Constructor taking a const char pointer.

The TCHAR * will contain the description returned from the virtual member function called what()

xCeption ( const SmartUtil::tstring &  err  )  throw ()

Overloaded Constructor basically doing the same as the const TCHAR * version.

See the const TCHAR * err overloaded version


Member Function Documentation

virtual DWORD getErrorCode (  )  const [virtual]

call from Windows API called in the Constructor

Returns the Windows Error code which is a DWORD, can be used in combination with FormatMessage from the
Windows API to get a descriptive Windows Error code explaining what went wrong (if it was a windows error)
You should in most cases rather use whatWndMsg to get a formatted message from Windows API.
Related Members

virtual const char* what (  )  const throw () [virtual]

Returns a descriptive error message explaining what went wrong.

Overridden from the std::exception::what()
Related Members

This function will ALWAYS return a char * string since it must be compliant with std::exception::what() function

virtual const TCHAR* whatWndMsg (  )  const [virtual]

Returns a descriptive windows error message explaining what went wrong.

Returns the formatted Windows Error message
Related Members

Back to SmartWin website
SourceForge.net Logo