librsb 1.3.0.2

Public Member Functions
RsbLib Class Reference

Class initializing/finalizing `librsb` state. More...

## Public Member Functions
RSBP_RVT Err_t | set_opt_str (const rsb_char_t *opnp, const rsb_char_t *opvp)
RSBP_RVT Err_t | set_opt (enum rsb_opt_t iof, const void *iop)
RSBP_RVT Err_t | get_opt (enum rsb_opt_t iof, void *iop) const
rsb_string_t | get_opt (enum rsb_opt_t iof) const
RSBP_RVT Err_t | set_num_threads (rsb_int_t nt)
rsb_int_t | get_num_threads (void) const
RSBP_RVT Err_t | reinit (struct rsb_initopts *iop)
RSBP_DEPRECATED | RsbLib (bool verbose)
| RsbLib (void)
size_t | meminfo (void)
| ~RsbLib (void)

## Detailed Description

Class initializing/finalizing `librsb` state.

Before creating any `RsbMatrix` objects, make sure you have initialized `librsb` by creating one single `RsbLib` object. Similarly, `RsbMatrix` object shall leave scope after the `RsbLib` object has been deallocated.

Several `librsb` options can be queried or changed via e.g. get_opt(), set_opt(), get_num_threads(), set_num_threads().

## Constructor & Destructor Documentation

## ◆ RsbLib() [1/2]

RSBP_DEPRECATED RsbLib::RsbLib | ( | bool | verbose | ) |
| inline

Initialize librsb.

See also
  rsb_lib_reinit().

## ◆ RsbLib() [2/2]

RsbLib::RsbLib | ( | void |  | ) |
| inline

Initialize librsb.

See also
  rsb_lib_reinit().

## ◆ ~RsbLib()

RsbLib::~RsbLib | ( | void |  | ) |
| inline

Destructor: finalize `librsb`.

This is being invoked at the end of the scope of a `RsbLib` object: typically at application's end.

## Member Function Documentation

## ◆ get_num_threads()

rsb_int_t RsbLib::get_num_threads | ( | void |  | ) | const
| inline

Indirect interface to rsb_lib_get_opt.

## ◆ get_opt() [1/2]

RSBP_RVT Err_t RsbLib::get_opt | ( | enum rsb_opt_t | iof,
|  | void * | iop
| ) |  | const
| inline

Interface to rsb_lib_get_opt.

## ◆ get_opt() [2/2]

rsb_string_t RsbLib::get_opt | ( | enum rsb_opt_t | iof | ) | const
| inline

Interface to rsb_lib_get_opt.

Warning
  Only RSB_IO_WANT_MEMORY_HIERARCHY_INFO_STRING is supported for now.

## ◆ meminfo()

size_t RsbLib::meminfo | ( | void |  | ) |
| inline

Provide memory debug info from librsb and return usage amount. Only effective if librsb configured accordingly.

On error, throw an exception.

## ◆ reinit()

RSBP_RVT Err_t RsbLib::reinit | ( | struct rsb_initopts * | iop | ) |
| inline

Interface to rsb_lib_reinit().

## ◆ set_num_threads()

RSBP_RVT Err_t RsbLib::set_num_threads | ( | rsb_int_t | nt | ) |
| inline

Indirect interface to rsb_lib_set_opt.

## ◆ set_opt()

RSBP_RVT Err_t RsbLib::set_opt | ( | enum rsb_opt_t | iof,
|  | const void * | iop
| ) |  |
| inline

Interface to rsb_lib_set_opt.

## ◆ set_opt_str()

RSBP_RVT Err_t RsbLib::set_opt_str | ( | const rsb_char_t * | opnp,
|  | const rsb_char_t * | opvp
| ) |  |
| inline

Interface to rsb_lib_set_opt_str.

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

- rsblib/rsb.hpp