ORIGINAL
|
Container for multiple heterogeneous elements. More...
#include <tuple.h>
Public Member Functions | |
tuple (const TYPES &... e) | |
tuple (const tuple &other) | |
tuple & | operator= (const tuple &other) |
tuple (tuple &&other) noexcept | |
tuple & | operator= (tuple &&other) noexcept |
template<u_integer IDX> | |
const auto & | get () const |
template<u_integer IDX> | |
auto & | get () |
template<u_integer IDX, typename E > | |
tuple & | set (const E &e) |
template<u_integer BEGIN_IDX, u_integer N_ELEMS> | |
auto | slice () const |
integer | compareTo (const tuple &other) const override |
std::string | toString (bool enter) const override |
Generates formatted string representation. | |
std::string | className () const override |
Gets the class name for type identification. | |
template<typename... O_TYPES, original::u_integer... T_SIZE, original::u_integer... O_SIZE> | |
original::tuple< TYPES..., O_TYPES... > | _concat (const tuple< O_TYPES... > &other, std::integer_sequence< u_integer, T_SIZE... >, std::integer_sequence< u_integer, O_SIZE... >) const |
template<original::u_integer IDX, typename E > | |
original::tuple< TYPES... > & | set (const E &e) |
![]() | |
operator std::string () const | |
Explicit conversion to std::string. | |
operator const char * () const | |
Explicit conversion to C-style string. | |
const char * | toCString (bool enter) const |
Direct C-string access with formatting control. | |
template<typename TYPE > | |
auto | formatString (const TYPE &t) -> std::string |
template<typename TYPE > | |
auto | formatCString (const TYPE &t) -> const char * |
template<typename TYPE > | |
auto | formatEnum (const TYPE &t) -> std::string |
template<typename TYPE > | |
auto | formatString (TYPE *const &ptr) -> std::string |
![]() | |
virtual integer | compareTo (const tuple< TYPES... > &other) const=0 |
Compares the current object with another of the same type. | |
bool | operator== (const tuple< TYPES... > &other) const |
Checks if the current object is equal to another. | |
bool | operator!= (const tuple< TYPES... > &other) const |
Checks if the current object is not equal to another. | |
bool | operator< (const tuple< TYPES... > &other) const |
Checks if the current object is less than another. | |
bool | operator> (const tuple< TYPES... > &other) const |
Checks if the current object is greater than another. | |
bool | operator<= (const tuple< TYPES... > &other) const |
Checks if the current object is less than or equal to another. | |
bool | operator>= (const tuple< TYPES... > &other) const |
Checks if the current object is greater than or equal to another. | |
virtual | ~comparable ()=default |
Virtual destructor for proper cleanup of derived objects. | |
Static Public Member Functions | |
static consteval u_integer | size () noexcept |
![]() | |
template<typename TYPE > | |
static std::string | formatString (const TYPE &t) |
Universal value-to-string conversion. | |
template<Printable TYPE> | |
static std::string | formatString (const TYPE &t) |
Specialization for printable types. | |
template<EnumType TYPE> | |
static std::string | formatString (const TYPE &t) |
Specialization for enum types. | |
template<typename TYPE > | |
static std::string | formatString (TYPE *const &ptr) |
Pointer-specific formatting. | |
template<typename TYPE > | |
static const char * | formatCString (const TYPE &t) |
C-string cache for temporary usage. | |
template<typename TYPE > | |
static std::string | formatEnum (const TYPE &t) |
Enum formatting utility. | |
template<> | |
auto | formatString (const char &t) -> std::string |
template<> | |
auto | formatString (const bool &t) -> std::string |
template<> | |
auto | formatString (const char *const &ptr) -> std::string |
Friends | |
template<typename F_TYPE , typename S_TYPE > | |
tuple< F_TYPE, S_TYPE > | makeTuple (const couple< F_TYPE, S_TYPE > &cp) |
template<typename... L_TYPES, typename... R_TYPES> | |
tuple< L_TYPES..., R_TYPES... > | operator+ (const tuple< L_TYPES... > <, const tuple< R_TYPES... > &rt) |
Container for multiple heterogeneous elements.
TYPES | Variadic template parameter list of element types |
Stores a sequence of elements with type safety. Provides:
|
overridevirtual |
Gets the class name for type identification.
Override in derived classes to provide accurate type names.
Reimplemented from original::printable.
|
overridevirtual |
Generates formatted string representation.
enter | Whether to append newline. |
Reimplemented from original::printable.