Function BitException

Summary

#include <include/bitexception.hpp>

(1) explicit BitException(const char *message, HRESULT code=E_FAIL)

(2) BitException(const char *message, DWORD code)

(3) explicit BitException(const wstring &message, HRESULT code=E_FAIL)

(4) BitException(const wstring &message, DWORD code)

Function overload

Synopsis

#include <include/bitexception.hpp>

explicit BitException(const char *message, HRESULT code=E_FAIL)

Description

Constructs a BitException object with the given message.

Parameters

message - the message associated with the exception object.

code - the HRESULT code associated with the exception object.

Source

Lines 37-37 in src/bitexception.cpp. Line 42 in include/bitexception.hpp.

BitException::BitException( const char* const message, HRESULT code ) : runtime_error( message ), mErrorCode( code ) {}

Synopsis

#include <include/bitexception.hpp>

BitException(const char *message, DWORD code)

Description

Constructs a BitException object with the given message.

Note
The Win32 error code is converted to a HRESULT code through HRESULT_FROM_WIN32 macro.
Parameters

message - the message associated with the exception object.

code - the Win32 error code associated with the exception object.

Source

Lines 39-40 in src/bitexception.cpp. Line 52 in include/bitexception.hpp.

BitException::BitException( const char* const message, DWORD code )
    : runtime_error( message ), mErrorCode( HRESULT_FROM_WIN32( code ) ) {}

Synopsis

#include <include/bitexception.hpp>

explicit BitException(const wstring &message, HRESULT code=E_FAIL)

Description

Constructs a BitException object with the given message.

Note
The wstring argument is converted into a string and then passed to the base class constructor.
Parameters

message - the message associated with the exception object.

code - the HRESULT code associated with the exception object.

Source

Lines 42-43 in src/bitexception.cpp. Line 63 in include/bitexception.hpp.

BitException::BitException( const wstring& message, HRESULT code )
    : runtime_error( ws2s( message ) ), mErrorCode( code ) {}

Synopsis

#include <include/bitexception.hpp>

BitException(const wstring &message, DWORD code)

Description

Constructs a BitException object with the given message.

Note
The wstring argument is converted into a string and then passed to the base class constructor.
Note
The Win32 error code is converted to a HRESULT code through HRESULT_FROM_WIN32 macro.
Parameters

message - the message associated with the exception object.

code - the Win32 error code associated with the exception object.

Source

Lines 45-46 in src/bitexception.cpp. Line 76 in include/bitexception.hpp.

BitException::BitException( const wstring& message, DWORD code )
    : runtime_error( ws2s( message ) ), mErrorCode( HRESULT_FROM_WIN32( code ) ) {}





Add Discussion as Guest

Log in