ORM C++
Loading...
Searching...
No Matches

Public Member Functions

constexpr Uuid () noexcept=default
constexpr Uuid (std::array< std::byte, 16 > valueInit) noexcept
constexpr auto bytes () const noexcept -> const std::array< std::byte, 16 > &
auto toString () const -> std::string
constexpr auto operator== (const Uuid &other) const noexcept -> bool
constexpr auto operator<=> (const Uuid &other) const noexcept -> std::strong_ordering

Static Public Member Functions

static auto parse (std::string_view text) -> Uuid

Detailed Description

A 128-bit UUID in canonical byte order, independent of a database backend.

Default construction produces the nil UUID. Parsing accepts exactly the 8-4-4-4-12 hexadecimal format, with either case; formatting uses lowercase. Every 128-bit pattern is representable. Byte ordering in C++ does not promise the same order as a database's native UUID comparisons.

Definition at line 77 of file values.cppm.

Constructor & Destructor Documentation

◆ Uuid() [1/2]

orm::Uuid::Uuid ( )
constexprdefaultnoexcept

◆ Uuid() [2/2]

orm::Uuid::Uuid ( std::array< std::byte, 16 > valueInit)
inlineexplicitconstexprnoexcept

Definition at line 82 of file values.cppm.

Member Function Documentation

◆ bytes()

auto orm::Uuid::bytes ( ) const -> const std::array< std::byte, 16 > &
inlinenodiscardconstexprnoexcept

Definition at line 84 of file values.cppm.

◆ operator<=>()

auto orm::Uuid::operator<=> ( const Uuid & other) const -> std::strong_ordering
inlineconstexprnoexcept

Definition at line 106 of file values.cppm.

◆ operator==()

auto orm::Uuid::operator== ( const Uuid & other) const -> bool
inlineconstexprnoexcept

Definition at line 94 of file values.cppm.

◆ parse()

auto orm::Uuid::parse ( std::string_view text) -> Uuid
staticnodiscard
Exceptions
std::invalid_argumentif the input is not in the required format.

◆ toString()

auto orm::Uuid::toString ( ) const -> std::string
nodiscard

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