Storage for the Seed objects, mainly for the purpose of the C ABI.
More...
#include <ots.hpp>
|
seed_handle_t | store (const Seed &seed) const noexcept |
| Stores a Seed object and returns a handle, to retrieve later.
|
|
const Seed & | get (seed_handle_t handle) const |
| retrieve a Seed object via a handle
|
|
const Seed & | get (const std::string &fingerprint) const |
| retrieve a Seed object from the jar from the fingerprint of the Seed object
|
|
uint32_t | count () const noexcept |
|
bool | has (seed_handle_t handle) const noexcept |
|
bool | has (const std::string &fingerprint) const |
|
std::vector< std::reference_wrapper< const Seed > > | list () const noexcept |
|
Storage for the Seed objects, mainly for the purpose of the C ABI.
- Todo:
- check if not better include in OTS
◆ count()
uint32_t ots::SeedJar::count |
( |
| ) |
const |
|
noexcept |
◆ get() [1/2]
const Seed & ots::SeedJar::get |
( |
const std::string & |
fingerprint | ) |
const |
retrieve a Seed object from the jar from the fingerprint of the Seed object
- Parameters
-
fingerprint | 6digit fingerprint of the Seed object |
- Returns
- The Seed object if in the jar
- Exceptions
-
◆ get() [2/2]
retrieve a Seed object via a handle
- Parameters
-
- See also
- store(Seed)
- Returns
- The Seed object if in the jar
- Exceptions
-
◆ has() [1/2]
bool ots::SeedJar::has |
( |
const std::string & |
fingerprint | ) |
const |
◆ has() [2/2]
◆ instance()
static const SeedJar & ots::SeedJar::instance |
( |
| ) |
|
|
staticnoexcept |
◆ list()
std::vector< std::reference_wrapper< const Seed > > ots::SeedJar::list |
( |
| ) |
const |
|
noexcept |
◆ store()
Stores a Seed object and returns a handle, to retrieve later.
- Parameters
-
seed | the actual Seed object to store |
- Returns
- the handle to retrieve the Seed object with
- See also
- get(seed_handle_t)
- Note
- Attempt to store various times the same Seed object, results in receiving same handle, without duplicating reference of the Seed object
The documentation for this class was generated from the following file:
- /projects/monerosigner/monero/ots/include/ots.hpp