DCL 4.0
Loading...
Searching...
No Matches
AssertError Class Reference

#include <Exception.h>

Inheritance diagram for AssertError:
Exception Object

Public Member Functions

 AssertError (const char_t *_filename, unsigned int _line, const char_t *_expr, const char_t *_message)
virtual String toString () const
Public Member Functions inherited from Exception
 Exception (Exception *_cause=NULL)
const Exceptioncause () const
String toStringAll () const
virtual void destroy ()
Public Member Functions inherited from Object
String className () const
bool isInstanceOf (const std::type_info &typeinfo) const
virtual const std::type_info & typeInfo () const

Static Public Member Functions

static String format (const char_t *_filename, unsigned int _line, const char_t *_expr, const char_t *_message)

Additional Inherited Members

Protected Member Functions inherited from Exception
virtual ~Exception ()
Protected Member Functions inherited from Object
virtual ~Object ()
 Object ()
Protected Attributes inherited from Exception
Exception__pCause

Detailed Description

Definition at line 180 of file Exception.h.

Constructor & Destructor Documentation

◆ AssertError()

AssertError::AssertError ( const char_t * _filename,
unsigned int _line,
const char_t * _expr,
const char_t * _message )

Member Function Documentation

◆ format()

String AssertError::format ( const char_t * _filename,
unsigned int _line,
const char_t * _expr,
const char_t * _message )
static

Definition at line 377 of file Exception.cpp.

383{
384 StringBuilder sb = L"Assertion Failed ! '";
385 sb += _expr;
386 sb += L"'";
387 if (_message)
388 {
389 sb += L" ";
390 sb += _message;
391 }
392 sb += L", File ";
393 sb += _filename;
394 sb += L":";
395 sb += Int32::toString((int32_t)_line, 10);
396
397
398 return sb;
399}
String toString(unsigned _base=10) const
Definition Numeric.inl:87

◆ toString()

String AssertError::toString ( ) const
virtual

Reimplemented from Exception.

Definition at line 371 of file Exception.cpp.

372{
373 return format(__filename, __line, __expr,
374 __message.isEmpty() ? NULL : __message.data());
375}
#define NULL
Definition Config.h:340
static String format(const char_t *_filename, unsigned int _line, const char_t *_expr, const char_t *_message)

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