Quick Links:

bal | bbl | bdl | bsl

Public Member Functions

bsls::AssertTestException Class Reference

#include <bsls_asserttestexception.h>

List of all members.

Public Member Functions

BSLS_KEYWORD_CONSTEXPR AssertTestException (const char *expression, const char *filename, int lineNumber, const char *level="UNKNOWN")
const char * expression () const
const char * filename () const
const char * level () const
int lineNumber () const

Detailed Description

This class is an implementation detail of the bsls testing framework and should not be used directly in user code. It implements an immutable mechanism to communicate information about the context of an assertion that fails to a test-case handler.

See Component bsls_asserttestexception


Constructor & Destructor Documentation

BSLS_KEYWORD_CONSTEXPR bsls::AssertTestException::AssertTestException ( const char *  expression,
const char *  filename,
int  lineNumber,
const char *  level = "UNKNOWN" 
)

Create a AssertTestException object with the specified expression, filename, lineNumber, and level. The behavior is undefined unless 0 < line and all of expression, filename, and level point to valid null-terminated character strings that will remain unmodified for the lifetime of this object (e.g., string literals).


Member Function Documentation

const char* bsls::AssertTestException::expression (  )  const

Return a string containing the program source of the assertion that has failed.

const char* bsls::AssertTestException::filename (  )  const

Return a string containing the filename of the source file containing the assertion that has failed.

const char* bsls::AssertTestException::level (  )  const

Return a string containing a representation of the level of assertion or review macro that failed.

int bsls::AssertTestException::lineNumber (  )  const

Return the number of the line within the file filename containing the assertion that failed.


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