Confdump Agent  1.4.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends
Public Member Functions | Public Attributes | Private Member Functions | Private Attributes
Confdump::System::Wmi::ComError Class Reference

Thrown on COM errors, contains specific information. More...

#include <errors.hpp>

Inheritance diagram for Confdump::System::Wmi::ComError:
Confdump::System::Wmi::Win32Error Confdump::RuntimeError

List of all members.

Public Member Functions

 ComError (HRESULT hr, QString action)
virtual ~ComError ()
QString errorMessage () const
 The system-provided error message (not always relevant)
HRESULT hresult () const
 The raw HRESULT value.
QString hresultAsHex () const
 hresult() as a 0x... string
virtual const char * what () const throw ()
void setMessage (QString message)

Public Attributes

HRESULT hresult_

Private Member Functions

 ComError ()

Private Attributes

_com_error comError_

Detailed Description

Thrown on COM errors, contains specific information.

what() will be formatted to contain the provided action, HRESULT code and any deduced system error message.

Most of the time you will want to use throwOnComError() instead.

Definition at line 112 of file Wmi/errors.hpp.


Constructor & Destructor Documentation

Confdump::System::Wmi::ComError::ComError ( HRESULT  hr,
QString  action 
)
  • action should be worded to fit "Failed to <action>"

Definition at line 59 of file Wmi/errors.cpp.

References errorMessage(), Confdump::System::Wmi::Win32Error::hresultAsHex(), and Confdump::RuntimeError::setMessage().

Definition at line 66 of file Wmi/errors.cpp.


Member Function Documentation

The system-provided error message (not always relevant)

Definition at line 70 of file Wmi/errors.cpp.

References comError_.

Referenced by ComError().

HRESULT Confdump::System::Wmi::Win32Error::hresult ( ) const [inherited]

The raw HRESULT value.

Definition at line 42 of file Wmi/errors.cpp.

References Confdump::System::Wmi::Win32Error::hresult_.

Referenced by Confdump::System::Wmi::WbemServices::execQuery().

QString Confdump::System::Wmi::Win32Error::hresultAsHex ( ) const [inherited]

hresult() as a 0x... string

Definition at line 47 of file Wmi/errors.cpp.

References Confdump::System::Wmi::Win32Error::hresult_.

Referenced by ComError(), and Confdump::System::Wmi::WmiError::WmiError().

void Confdump::RuntimeError::setMessage ( QString  message) [inherited]
const char * Confdump::RuntimeError::what ( ) const throw () [virtual, inherited]

Definition at line 38 of file RuntimeError.cpp.

References Confdump::RuntimeError::message_.

Referenced by main().


Member Data Documentation

Definition at line 127 of file Wmi/errors.hpp.

Referenced by errorMessage().


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends