Shared charge that can explicitly follow one payload across queues or work.
More...
#include <StormByte/buffer/byte_budget.hxx>
|
| | Lease () noexcept=default |
| | Construct an empty charge.
|
| | Lease (const Lease &other) noexcept=default |
| | Share an existing charge without reserving twice.
|
| | Lease (Lease &&other) noexcept=default |
| | Transfer a charge.
|
| | ~Lease () noexcept=default |
| | Release this reference; final release returns bytes.
|
| Lease & | operator= (const Lease &other) noexcept=default |
| | Replace this reference with a shared charge.
|
| Lease & | operator= (Lease &&other) noexcept=default |
| | Replace this reference with a transferred charge.
|
| | operator bool () const noexcept |
| | Whether a charge is owned, including a zero-byte charge.
|
| StormByte::ByteSize | Bytes () const noexcept |
| | Size reserved once for all copies.
|
| bool | BelongsTo (const ByteBudget &budget) const noexcept |
| | Check shared budget identity.
|
| void | Reset () noexcept |
| | Release this reference.
|
Shared charge that can explicitly follow one payload across queues or work.
◆ Lease() [1/3]
| StormByte::Buffer::ByteBudget::Lease::Lease |
( |
| ) |
|
|
defaultnoexcept |
Construct an empty charge.
◆ Lease() [2/3]
| StormByte::Buffer::ByteBudget::Lease::Lease |
( |
const Lease & | other | ) |
|
|
defaultnoexcept |
Share an existing charge without reserving twice.
- Parameters
-
◆ Lease() [3/3]
| StormByte::Buffer::ByteBudget::Lease::Lease |
( |
Lease && | other | ) |
|
|
defaultnoexcept |
Transfer a charge.
- Parameters
-
◆ ~Lease()
| StormByte::Buffer::ByteBudget::Lease::~Lease |
( |
| ) |
|
|
defaultnoexcept |
Release this reference; final release returns bytes.
◆ BelongsTo()
| bool StormByte::Buffer::ByteBudget::Lease::BelongsTo |
( |
const ByteBudget & | budget | ) |
const |
|
noexcept |
Check shared budget identity.
- Parameters
-
- Returns
- True when charged to that budget.
◆ Bytes()
Size reserved once for all copies.
- Returns
- Logical bytes.
◆ operator bool()
| StormByte::Buffer::ByteBudget::Lease::operator bool |
( |
| ) |
const |
|
explicitnoexcept |
Whether a charge is owned, including a zero-byte charge.
- Returns
- True for a live charge.
◆ operator=() [1/2]
| Lease & StormByte::Buffer::ByteBudget::Lease::operator= |
( |
const Lease & | other | ) |
|
|
defaultnoexcept |
Replace this reference with a shared charge.
- Parameters
-
- Returns
- This lease.
◆ operator=() [2/2]
| Lease & StormByte::Buffer::ByteBudget::Lease::operator= |
( |
Lease && | other | ) |
|
|
defaultnoexcept |
Replace this reference with a transferred charge.
- Parameters
-
- Returns
- This lease.
◆ Reset()
| void StormByte::Buffer::ByteBudget::Lease::Reset |
( |
| ) |
|
|
noexcept |
◆ ByteBudget
The documentation for this class was generated from the following file: