glibmm: Glib::Error Class Reference

glibmm 2.66.6

Public Member Functions | Protected Attributes | List of all members
Glib::Error Class Reference

`#include <glibmm/error.h>`

Inheritance diagram for Glib::Error:
[legend]

## Public Member Functions
| Error ()
| Error (GQuark error_domain, int error_code, const Glib::ustring & message)
| Error (GError * gobject, bool take_copy=false)
| Error (const Error & other)
Error & | operator= (const Error & other)
| ~Error () noexcept override
| operator bool () const
| Test whether the Error has an underlying instance.
GQuark | domain () const
int | code () const
Glib::ustring | what () const override
bool | matches (GQuark error_domain, int error_code) const
GError * | gobj ()
const GError * | gobj () const
Public Member Functions inherited from Glib::Exception
virtual | ~Exception () noexcept=0
virtual Glib::ustring | what () const =0

## Protected Attributes
GError * | gobject_

## Constructor & Destructor Documentation

## ◆ Error() [1/4]

Glib::Error::Error | ( |  | ) |

## ◆ Error() [2/4]

Glib::Error::Error | ( | GQuark | error_domain,
|  | int | error_code,
|  | const Glib::ustring & | message
| ) |  |

## ◆ Error() [3/4]

Glib::Error::Error | ( | GError * | gobject,
|  | bool | take_copy = `false`
| ) |  |
| explicit

## ◆ Error() [4/4]

Glib::Error::Error | ( | const Error & | other | ) |

## ◆ ~Error()

Glib::Error::~Error | ( |  | ) |
| overridenoexcept

## Member Function Documentation

## ◆ code()

int Glib::Error::code | ( |  | ) | const

## ◆ domain()

GQuark Glib::Error::domain | ( |  | ) | const

## ◆ gobj() [1/2]

GError * Glib::Error::gobj | ( |  | ) |

## ◆ gobj() [2/2]

const GError * Glib::Error::gobj | ( |  | ) | const

## ◆ matches()

bool Glib::Error::matches | ( | GQuark | error_domain,
|  | int | error_code
| ) |  | const

## ◆ operator bool()

Glib::Error::operator bool | ( |  | ) | const
| explicit

Test whether the Error has an underlying instance.

Since glibmm 2.60:

## ◆ operator=()

Error & Glib::Error::operator= | ( | const Error & | other | ) |

## ◆ what()

Glib::ustring Glib::Error::what | ( |  | ) | const
| overridevirtual

Implements Glib::Exception.

## Member Data Documentation

## ◆ gobject_

GError* Glib::Error::gobject_
| protected