ORIGINAL
|
Main namespace for the project Original. More...
Classes | |
class | absTransform |
Transformation that converts an element to its absolute value. More... | |
class | addOptTransform |
Transformation that adds a given value to an element. More... | |
class | algorithms |
Utility class containing generic container algorithms. More... | |
class | allocateError |
Exception for memory allocation failures. More... | |
class | allocator |
Default memory allocator using allocators utilities. More... | |
class | allocatorBase |
Interface for other memory allocator implementations. More... | |
class | allocators |
Utility class providing static memory allocation/de-allocation functions. More... | |
class | alternative |
A type-safe container that may or may not contain a value. More... | |
class | alternative< void > |
class | array |
A fixed-size array container with random access. More... | |
class | assignOptTransform |
Transformation that assigns a specified value to an element. More... | |
class | async |
Asynchronous programming utilities with future/promise pattern. More... | |
class | autoPtr |
Base smart pointer with reference counting. More... | |
class | baseArray |
Base class for fixed-size serial containers. More... | |
class | baseCloneable |
Base class that defines a cloneable interface. More... | |
class | baseIterator |
A base class for basic iterators. More... | |
class | baseList |
Base class for variable-size serial containers. More... | |
class | bitSet |
A class representing a set of bits, offering functionality to manipulate and query individual bits. More... | |
class | blocksList |
A block-based list implementation. More... | |
class | callBackChecker |
Static utility for validating callback signatures. More... | |
class | callbackReturnTypeError |
Exception for callback return type mismatch. More... | |
class | callbackSignatureError |
Exception for callback argument mismatch. More... | |
class | chain |
Non-cyclic doubly linked list container. More... | |
class | cloneable |
Concrete cloneable class with custom cloning behavior. More... | |
class | comparable |
Base class for comparable objects. More... | |
class | comparator |
Base class for comparison. More... | |
class | conditionBase |
Abstract base class for condition variable implementations. More... | |
class | container |
Abstract base class for containers. More... | |
class | containerAdapter |
Adapter class that provides unified interface for various container types. More... | |
class | copyTransform |
Transformation that copies an element into a container. More... | |
class | coroutine |
Namespace for coroutine-related utilities and generator implementation. More... | |
class | couple |
Container for two heterogeneous elements. More... | |
class | decreaseComparator |
Comparator for decreasing comparison (greater than). More... | |
class | decreaseNotStrictComparator |
Comparator for non-strict decreasing comparison (greater than or equal to). More... | |
class | deleter |
Default deletion policy for single objects. More... | |
class | deleter< TYPE[]> |
class | deleterBase |
Base class for deleters defining the deletion policy interface. More... | |
class | deleterBase< TYPE[], DERIVED > |
class | deque |
Double-ended queue container adapter. More... | |
class | doubleDirectionIterator |
Abstract base class for double-direction iterators. More... | |
class | equalComparator |
Comparator for equality comparison. More... | |
class | equalFilter |
A filter that checks if an element is equal to a target value. More... | |
class | error |
Base class for all exceptions in the Original project. More... | |
class | filter |
Base class for filter operations. More... | |
class | filterStream |
Composite filter builder with logical operator chaining. More... | |
class | forwardChain |
A singly linked list implementation. More... | |
struct | functionTraits |
Primary template for general callable types. More... | |
struct | functionTraits< R(*)(Args...)> |
Specialization for function pointers. More... | |
struct | functionTraits< R(Args...)> |
Specialization for function types. More... | |
struct | functionTraits< R(C::*)(Args...) const > |
Specialization for const member function pointers. More... | |
struct | functionTraits< R(C::*)(Args...)> |
Specialization for non-const member function pointers. More... | |
class | genPipe |
Pipe adapter for generator operations to enable fluent chaining. More... | |
class | greaterFilter |
A filter that checks if an element is greater than a target value. More... | |
class | hash |
Generic hash function object supporting multiple types. More... | |
class | hashable |
Forward declaration of hashable interface template. More... | |
class | hashMap |
Hash table based implementation of the map interface. More... | |
class | hashSet |
Hash table based implementation of the set interface. More... | |
class | hashTable |
Hash table implementation with separate chaining. More... | |
class | increaseComparator |
Comparator for increasing comparison (less than). More... | |
class | increaseNotStrictComparator |
Comparator for non-strict increasing comparison (less than or equal to). More... | |
class | indexSequence |
Compile-time sequence of unsigned integers. More... | |
class | iterable |
A base class for iterable containers that support multiple iteration patterns. More... | |
class | iterationStream |
A stream class that allows iteration, comparison, hashing and printing. More... | |
class | iterator |
Base iterator interface that supports common operations for iteration. More... | |
class | JMap |
Skip List based implementation of the map interface. More... | |
class | JSet |
Skip List based implementation of the set interface. More... | |
class | lessFilter |
A filter that checks if an element is less than a target value. More... | |
class | lockGuard |
Abstract base class for lock guard implementations. More... | |
class | makeIndexSequence |
Utility for generating index sequences. More... | |
class | map |
Abstract base class for key-value mapping containers. More... | |
class | multiLock |
RAII wrapper for multiple mutex locking. More... | |
class | multiOptTransform |
Transformation that multiplies an element by a given value. More... | |
class | mutexBase |
Abstract base class for mutex implementations. More... | |
class | noElementError |
Exception for missing element requests. More... | |
class | none |
A placeholder type representing the absence of a value. More... | |
class | notEqualComparator |
Comparator for inequality comparison. More... | |
class | notEqualFilter |
A filter that checks if an element is not equal to a target value. More... | |
class | notGreaterFilter |
A filter that checks if an element is less than or equal to a target value. More... | |
class | notLessFilter |
A filter that checks if an element is greater than or equal to a target value. More... | |
class | nullPointerError |
Exception for null pointer dereference attempts. More... | |
class | objPoolAllocator |
Object pool allocator for efficient fixed-size memory management. More... | |
class | outOfBoundError |
Exception for container index out-of-range errors. More... | |
class | ownerPtr |
Unique ownership smart pointer with move semantics. More... | |
class | pCondition |
POSIX condition variable implementation. More... | |
class | pMutex |
POSIX thread mutex implementation. More... | |
class | printable |
Base class providing polymorphic string conversion capabilities. More... | |
class | prique |
Heap-based priority queue container. More... | |
class | pThread |
POSIX thread implementation. More... | |
class | queue |
First-In-First-Out (FIFO) container adapter. More... | |
class | randomAccessIterator |
Abstract base class for random-access iterators. More... | |
class | rangeFilter |
A filter that checks if an element lies within a specified range. More... | |
class | RBTree |
Red-Black Tree container implementation. More... | |
class | refCntPtr |
Base class for reference-counted pointers. More... | |
class | refCount |
Reference counting metadata container. More... | |
class | refCountBase |
Base class for reference counting metadata. More... | |
class | semaphore |
Counting semaphore with maximum count constraint. More... | |
class | semaphore< 0 > |
class | semaphoreGuard |
RAII wrapper for automatic semaphore management. More... | |
class | serial |
Abstract base class for sequential containers with index-based access. More... | |
class | set |
Abstract base class for unique element containers. More... | |
class | singleDirectionIterator |
Abstract base class for single-direction iterators. More... | |
class | singleton |
Thread-safe singleton pattern implementation with ownership management. More... | |
class | skipList |
Skip List container implementation. More... | |
class | stack |
Last-In-First-Out (LIFO) container adapter. More... | |
class | staticError |
Compile-time error triggering utility. More... | |
class | staticError< original::allocateError, TRIGGERING_CONDITION > |
class | staticError< original::callbackReturnTypeError, TRIGGERING_CONDITION > |
class | staticError< original::callbackSignatureError, TRIGGERING_CONDITION > |
class | staticError< original::error, TRIGGERING_CONDITION > |
class | staticError< original::noElementError, TRIGGERING_CONDITION > |
class | staticError< original::nullPointerError, TRIGGERING_CONDITION > |
class | staticError< original::outOfBoundError, TRIGGERING_CONDITION > |
class | staticError< original::sysError, TRIGGERING_CONDITION > |
class | staticError< original::unSupportedMethodError, TRIGGERING_CONDITION > |
class | staticError< original::valueError, TRIGGERING_CONDITION > |
class | stepIterator |
Abstract base class for step iterators. More... | |
class | strongPtr |
Shared ownership smart pointer with strong references. More... | |
class | syncPoint |
Synchronization point for multiple threads. More... | |
class | sysError |
Exception for generic system failure. More... | |
class | taskDelegator |
Thread pool for managing and executing prioritized tasks. More... | |
class | thread |
High-level thread wrapper. More... | |
class | threadBase |
Base class for thread implementations. More... | |
class | time |
Namespace-like class containing time-related utilities. More... | |
class | transform |
Base class for transformation operations. More... | |
class | transformStream |
Ordered sequence of transformation operations. More... | |
class | treeMap |
Red-Black Tree based implementation of the map interface. More... | |
class | treeSet |
Red-Black Tree based implementation of the set interface. More... | |
class | tuple |
Container for multiple heterogeneous elements. More... | |
class | uniqueLock |
RAII wrapper for single mutex locking. More... | |
class | unSupportedMethodError |
Exception for unimplemented method calls. More... | |
class | valueError |
Exception for invalid parameter values. More... | |
class | vector |
Dynamic array container with amortized constant time operations. More... | |
class | weakPtr |
Non-owning reference to shared resource. More... | |
class | wrapper |
Base class for linked value containers with formatted output. More... | |
Concepts | |
concept | NotNull |
Ensures the parameter pack is not empty. | |
concept | EnumType |
Requires type to be an enumeration. | |
concept | EnumClassType |
Requires type to be a scoped enumeration. | |
concept | EqualityComparable |
Requires type to support equality comparison operators. | |
concept | WeaklyOrdered |
Requires type to support relational comparison operators. | |
concept | PartiallyComparable |
Requires type to support either equality or relational comparisons. | |
concept | TotallyComparable |
Requires type to support all comparison operators. | |
concept | ThreeWayComparable |
Requires type to support three-way comparison (spaceship operator). | |
concept | StronglyOrdered |
Requires type to support strong ordering via three-way comparison. | |
concept | Comparable |
concept | CmpTraits |
Requires type to implement the comparable interface with compareTo method. | |
concept | Printable |
Requires type to support output stream insertion. | |
concept | InputStreamable |
Requires type to support input stream extraction. | |
concept | Streamable |
Requires type to support both input and output stream operations. | |
concept | Hashable |
Concept checking for types that can be hashed. | |
concept | Equatable |
Requires type to support equality comparison for hashing. | |
concept | HashTraits |
Requires type to implement the hashable interface with toHash method. | |
concept | Callable |
Basic concept for any callable type. | |
concept | CallbackOf |
Validates callback signature compatibility. | |
concept | Predicate |
Constraint for boolean predicate callbacks. | |
concept | Compare |
Combines Comparable and CallbackOf for comparison callbacks. | |
concept | Condition |
Constraint for predicate callbacks. | |
concept | Operation |
Constraint for mutating operations. | |
concept | Transformer |
Constraint for transformation operations. | |
concept | SuperOf |
Checks inheritance or type equality. | |
concept | ExtendsOf |
Checks derivation or type identity using std::derived_from. | |
concept | ConvertibleTo |
Checks if type is convertible to another type. | |
concept | SameAs |
Checks if two types are exactly the same. | |
concept | Container |
Basic container concept. | |
concept | SequenceContainer |
Sequence container concept. | |
Typedefs | |
using | byte = std::uint8_t |
Unsigned 8-bit integer type (byte) | |
using | s_byte = std::int8_t |
Signed 8-bit integer type. | |
using | integer = std::int64_t |
64-bit signed integer type for arithmetic operations | |
using | u_integer = std::uint32_t |
32-bit unsigned integer type for sizes and indexes | |
using | ul_integer = std::uint64_t |
64-bit unsigned integer type | |
using | floating = double |
Double-precision floating-point type. | |
using | l_floating = long double |
Extended precision floating-point type. | |
template<u_integer N> | |
using | makeReverseSequence = decltype(reverseIndexSequenceImpl(makeSequence< N >())) |
Creates a reversed index sequence. | |
Functions | |
template<typename T , typename DER , typename DEL > | |
bool | operator== (const autoPtr< T, DER, DEL > &ptr, const std::nullptr_t &null) |
Equality comparison with nullptr. | |
template<typename T , typename DER , typename DEL > | |
bool | operator!= (const autoPtr< T, DER, DEL > &ptr, const std::nullptr_t &null) |
Inequality comparison with nullptr. | |
template<typename T , typename DER , typename DEL > | |
bool | operator== (const std::nullptr_t &null, const autoPtr< T, DER, DEL > &ptr) |
Equality comparison with nullptr (reversed operands) | |
template<typename T , typename DER , typename DEL > | |
bool | operator!= (const std::nullptr_t &null, const autoPtr< T, DER, DEL > &ptr) |
Inequality comparison with nullptr (reversed operands) | |
template<typename ALLOC_ > | |
bitSet< ALLOC_ > | operator& (const bitSet< ALLOC_ > &lbs, const bitSet< ALLOC_ > &rbs) |
Bitwise AND operator for two bitSets. | |
template<typename ALLOC_ > | |
bitSet< ALLOC_ > | operator| (const bitSet< ALLOC_ > &lbs, const bitSet< ALLOC_ > &rbs) |
Bitwise OR operator for two bitSets. | |
template<typename ALLOC_ > | |
bitSet< ALLOC_ > | operator^ (const bitSet< ALLOC_ > &lbs, const bitSet< ALLOC_ > &rbs) |
Bitwise XOR operator for two bitSets. | |
template<typename ALLOC_ > | |
bitSet< ALLOC_ > | operator~ (const bitSet< ALLOC_ > &bs) |
Bitwise NOT operator for a bitSet. | |
consteval bool | ON_WINDOWS () |
Checks if compiling for Windows platform. | |
consteval bool | ON_WIN32 () |
Checks if compiling for 32-bit Windows. | |
consteval bool | ON_WIN64 () |
Checks if compiling for 64-bit Windows. | |
consteval bool | ON_LINUX () |
Checks if compiling for Linux platform. | |
consteval bool | ON_MACOS () |
Checks if compiling for macOS platform. | |
consteval bool | ON_UNIX () |
Checks if compiling for Unix-like platform (excluding Linux/macOS) | |
consteval bool | ON_UNKNOWN_PLATFORM () |
Checks if compiling for unknown platform. | |
consteval bool | USING_CLANG () |
Checks if compiling with Clang. | |
consteval bool | USING_GCC () |
Checks if compiling with GCC. | |
consteval bool | USING_MSVC () |
Checks if compiling with MSVC. | |
consteval bool | USING_UNKNOWN_COMPLIER () |
Checks if compiling with unknown compiler. | |
template<typename T > | |
filterStream< T > | operator&& (const filter< T > &f1, const filter< T > &f2) |
Create AND filterStream from two filters. | |
template<typename T > | |
filterStream< T > | operator&& (const filter< T > &f, const filterStream< T > &ofs) |
AND operator between filter and filterStream. | |
template<typename T > | |
filterStream< T > | operator&& (const filterStream< T > &ofs, const filter< T > &f) |
AND operator between filterStream and filter. | |
template<typename T > | |
filterStream< T > | operator|| (const filter< T > &f1, const filter< T > &f2) |
Create OR filterStream from two filters. | |
template<typename T > | |
filterStream< T > | operator|| (const filter< T > &f, const filterStream< T > &ofs) |
OR operator between filter and filterStream. | |
template<typename T > | |
filterStream< T > | operator|| (const filterStream< T > &ofs, const filter< T > &f) |
OR operator between filterStream and filter. | |
template<typename T > | |
filterStream< T > | operator! (const filter< T > &f) |
Create negated filterStream from filter. | |
template<typename T > | |
filterStream< T > | operator! (const filterStream< T > &ofs) |
Create negated filterStream from existing stream. | |
template<typename T > | |
filterStream< T > | group (const filterStream< T > &ofs) |
Create grouped filterStream from existing stream. | |
template<typename T > | |
filterStream< T > | group (const filter< T > &f) |
Create grouped filterStream from single filter. | |
template<typename T > | |
auto | operator+ (const iterator< T > &it, integer steps) -> iterator< T > * |
Adds a number of steps to the iterator's current position and returns a new iterator. | |
template<typename T > | |
auto | operator- (const iterator< T > &it, integer steps) -> iterator< T > * |
Subtracts a number of steps from the iterator's current position and returns a new iterator. | |
template<typename T > | |
bool | operator== (const iterator< T > &l_it, const iterator< T > &r_it) |
Equality comparison operator for iterators. | |
template<typename T > | |
bool | operator!= (const iterator< T > &l_it, const iterator< T > &r_it) |
Inequality comparison operator for iterators. | |
template<typename TYPE > | |
TYPE | abs (TYPE a) |
Returns the absolute value of a given number. | |
template<typename TYPE > | |
TYPE | max (TYPE a, TYPE b) |
Returns the larger of two given values. | |
template<typename TYPE > | |
TYPE | min (TYPE a, TYPE b) |
Returns the smaller of two given values. | |
floating | pow (floating base, integer exp) |
Returns the result of raising a base to an exponent. | |
template<std::integral INTEGER = int> | |
coroutine::generator< INTEGER > | rangesOf (INTEGER start, INTEGER end, INTEGER steps=1) |
Generates a sequence of integers from start to end (exclusive) with a given steps . | |
template<typename T , typename DEL = deleter<T>, typename... Args> | |
ownerPtr< T, DEL > | makeOwnerPtr (Args &&... args) |
Creates a new ownerPtr managing a dynamically allocated object. | |
template<typename T , typename DEL = deleter<T[]>, typename... Args> | |
ownerPtr< T, DEL > | makeOwnerPtrArray (u_integer size, Args &&... args) |
Creates a new ownerPtr managing a dynamically allocated array. | |
std::ostream & | operator<< (std::ostream &os, const printable &p) |
Stream insertion operator for printable objects. | |
template<typename T , typename DEL = deleter<T>, typename... Args> | |
strongPtr< T, DEL > | makeStrongPtr (Args &&... args) |
Creates a new strongPtr managing a shared object. | |
template<typename T , typename DEL = deleter<T[]>, typename... Args> | |
strongPtr< T, DEL > | makeStrongPtrArray (u_integer size, Args &&... args) |
Creates a new strongPtr managing a shared array. | |
template<typename T > | |
transformStream< T > | operator+ (const transform< T > &t1, const transform< T > &t2) |
Creates new transformation stream from two transforms. | |
template<typename T > | |
transformStream< T > | operator+ (const transform< T > &t, const transformStream< T > &ots) |
Creates new stream by prefixing existing stream. | |
template<typename F_TYPE , typename S_TYPE > | |
tuple< F_TYPE, S_TYPE > | makeTuple (const couple< F_TYPE, S_TYPE > &cp) |
Creates a tuple from a couple (copy version) | |
template<typename F_TYPE , typename S_TYPE > | |
tuple< F_TYPE, S_TYPE > | makeTuple (couple< F_TYPE, S_TYPE > &&cp) |
Creates a tuple from a couple (move version) | |
template<u_integer NUM> | |
consteval auto | makeSequence () noexcept |
Creates an index sequence of given length. | |
template<u_integer... Indices> | |
consteval auto | reverseIndexSequenceImpl (indexSequence< Indices... > seq) |
Implementation detail for reversing an index sequence. | |
template<typename T , typename... ARGS> | |
vector< T > | makeVector (u_integer size, ARGS &&... args) |
template<typename T , typename Callback > | |
auto | operator| (async::future< T > f, Callback &&c) |
Pipe operator for chaining asynchronous computations. | |
template<typename Callback > | |
auto | operator| (async::future< void > f, Callback &&c) |
Pipe operator specialization for future<void> | |
template<typename T , typename Callback > | |
auto | operator| (async::sharedFuture< T > sf, Callback &&c) |
Pipe operator for chaining computations on sharedFuture. | |
template<typename Callback > | |
auto | operator| (async::sharedFuture< void > sf, Callback &&c) |
Pipe operator specialization for sharedFuture<void> | |
template<typename T , typename Callback1 , typename Callback2 > | |
auto | operator| (async::promise< T, Callback1 > p, Callback2 &&c) |
Lazy pipe operator for chaining promise computations. | |
template<typename Callback1 , typename Callback2 > | |
auto | operator| (async::promise< void, Callback1 > p, Callback2 &&c) |
Lazy pipe operator specialization for promise<void> | |
template<typename TYPE > | |
coroutine::generator< couple< u_integer, TYPE > > | enumerate (coroutine::generator< TYPE > gen) |
Enumerates elements of a generator with their indices. | |
template<typename TYPE , typename SET = hashSet<TYPE>> requires ExtendsOf<set<TYPE, allocator<couple<const TYPE, const bool>>>, SET> | |
SET | collect (coroutine::generator< TYPE > gen) |
Collects generator elements into a set. | |
template<typename TYPE , template< typename > typename SERIAL = vector> requires ExtendsOf<baseList<TYPE, allocator<TYPE>>, SERIAL<TYPE>> | |
SERIAL< TYPE > | list (coroutine::generator< TYPE > gen) |
Collects generator elements into a list container. | |
template<typename TYPE , typename Callback > | |
auto | transforms (coroutine::generator< TYPE > gen, Callback &&c) -> coroutine::generator< std::invoke_result_t< Callback, TYPE > > |
Transforms generator elements using a callable. | |
template<typename TYPE , typename Callback > | |
coroutine::generator< TYPE > | filters (coroutine::generator< TYPE > gen, Callback &&c) |
Filters generator elements based on a predicate. | |
template<typename TYPE , typename Callback > | |
coroutine::generator< TYPE > | extract (coroutine::generator< TYPE > gen, Callback &&c) |
Extracts elements that do not satisfy a predicate. | |
template<typename T , typename U > | |
coroutine::generator< couple< T, U > > | zip (coroutine::generator< T > gen1, coroutine::generator< U > gen2) |
Zips two generators into pairs. | |
template<typename TYPE > | |
u_integer | count (coroutine::generator< TYPE > gen) |
Counts total elements in a generator. | |
template<typename TYPE , typename Callback > | |
u_integer | count (coroutine::generator< TYPE > gen, Callback &&c) |
Counts elements satisfying a predicate. | |
template<typename TYPE , typename Callback > | |
bool | all (coroutine::generator< TYPE > gen, Callback &&c) |
Checks if all elements satisfy a predicate. | |
template<typename TYPE , typename Callback > | |
bool | none (coroutine::generator< TYPE > gen, Callback &&c) |
Checks if no elements satisfy a predicate. | |
template<typename TYPE , typename Callback > | |
bool | any (coroutine::generator< TYPE > gen, Callback &&c) |
Checks if any element satisfies a predicate. | |
template<typename T , std::convertible_to< T > U> | |
coroutine::generator< T > | join (coroutine::generator< T > gen1, coroutine::generator< U > gen2) |
Joins two generators of compatible types. | |
template<typename T , std::convertible_to< T > U> | |
coroutine::generator< T > | flatten (coroutine::generator< couple< T, U > > gen) |
Flattens a generator of couples into a single generator. | |
template<typename TYPE > | |
coroutine::generator< TYPE > | take (coroutine::generator< TYPE > gen, u_integer n) |
Takes the first n elements from a generator. | |
template<typename TYPE > | |
coroutine::generator< TYPE > | skip (coroutine::generator< TYPE > gen, u_integer n) |
Skips the first n elements of a generator. | |
template<typename TYPE , typename Callback > | |
u_integer | position (coroutine::generator< TYPE > gen, Callback &&c) |
Finds the position of the first element satisfying a predicate. | |
template<typename TYPE , typename Callback > | |
TYPE | find (coroutine::generator< TYPE > gen, Callback &&c) |
Finds the first element satisfying a predicate. | |
template<typename TYPE , typename F > | |
auto | operator| (coroutine::generator< TYPE > gen, genPipe< F > p) |
Pipe operator for generator operations. | |
template<typename F > | |
auto | transforms (F &&f) |
Creates a transform pipe operation. | |
template<typename F > | |
auto | filters (F &&f) |
Creates a filter pipe operation. | |
template<typename F > | |
auto | extract (F &&f) |
Creates an extract pipe operation. | |
template<typename = void> | |
auto | enumerate () |
Creates an enumerate pipe operation. | |
template<typename = void> | |
auto | take (u_integer n) |
Creates a take pipe operation. | |
template<typename = void> | |
auto | skip (u_integer n) |
Creates a skip pipe operation. | |
template<typename T , typename U > | |
auto | join (coroutine::generator< U > gen2) |
Creates a join pipe operation. | |
template<typename T , typename U > | |
auto | flatten () |
Creates a flatten pipe operation. | |
template<typename U > | |
auto | zipWith (coroutine::generator< U > gen2) |
Creates a zipWith pipe operation. | |
template<typename = void> | |
auto | count () |
Creates a count pipe operation. | |
template<typename F > | |
auto | count (F &&f) |
Creates a conditional count pipe operation. | |
template<typename F > | |
auto | all (F &&f) |
Creates an all-match pipe operation. | |
template<typename F > | |
auto | none (F &&f) |
Creates a none-match pipe operation. | |
template<typename F > | |
auto | any (F &&f) |
Creates an any-match pipe operation. | |
template<typename F > | |
auto | position (F &&f) |
Creates a position-finding pipe operation. | |
template<typename F > | |
auto | find (F &&f) |
Creates an element-finding pipe operation. | |
time::duration | nanoseconds (time::time_val_type val=1) |
time::duration | microseconds (time::time_val_type val=1) |
time::duration | milliseconds (time::time_val_type val=1) |
time::duration | seconds (time::time_val_type val=1) |
time::duration | minutes (time::time_val_type val=1) |
time::duration | hours (time::time_val_type val=1) |
time::duration | days (time::time_val_type val=1) |
time::duration | operator- (const time::duration &d) |
time::duration | operator+ (const time::duration &lhs, const time::duration &rhs) |
time::duration | operator- (const time::duration &lhs, const time::duration &rhs) |
time::duration | operator* (const time::duration &d, time::time_val_type factor) |
time::duration | operator* (time::time_val_type factor, const time::duration &d) |
time::duration | operator/ (const time::duration &d, time::time_val_type factor) |
time::duration | operator/ (const time::duration &lhs, const time::duration &rhs) |
time::duration | abs (const time::duration &d) |
time::point | operator+ (const time::point &p, const time::duration &d) |
time::point | operator+ (const time::duration &d, const time::point &p) |
time::point | operator- (const time::point &p, const time::duration &d) |
time::duration | operator- (const time::point &lhs, const time::point &rhs) |
time::UTCTime | operator+ (const time::UTCTime &t, const time::duration &d) |
time::UTCTime | operator+ (const time::duration &d, const time::UTCTime &t) |
time::UTCTime | operator- (const time::UTCTime &t, const time::duration &d) |
time::duration | operator- (const time::UTCTime &lhs, const time::UTCTime &rhs) |
Variables | |
constexpr l_floating | E = 2.7182818284590452353602874713526624977572470937000 |
The mathematical constant E (Euler's number). | |
constexpr l_floating | PI = 3.1415926535897932384626433832795028841971693993751 |
The mathematical constant PI (π). | |
Main namespace for the project Original.
The main namespace containing all core type system components.
Main namespace containing all hashing utilities.
This namespace serves as the main container for all modules and functionality within the Original project. It includes various classes, functions, and data structures that form the backbone of the system.
using original::makeReverseSequence = typedef decltype( reverseIndexSequenceImpl(makeSequence<N>()) ) |
Creates a reversed index sequence.
N | Length of the sequence to create |
|
inline |
d | Duration to get absolute value of |
Returns the absolute value of a given number.
TYPE | The type of the input value. |
a | The input value. |
This function returns the absolute value of the input argument a
, which is the distance of a
from zero. It works for both positive and negative values. For unsigned types, returns the value unchanged.
bool original::all | ( | coroutine::generator< TYPE > | gen, |
Callback && | c | ||
) |
Checks if all elements satisfy a predicate.
TYPE | The element type. |
Callback | The predicate function type. |
gen | The generator to check. |
c | The validation predicate. |
Short-circuits on first false result. Returns true for empty generators.
Example:
Creates an all-match pipe operation.
F | The predicate function type. |
f | The validation predicate. |
Factory function for creating all-match operations.
bool original::any | ( | coroutine::generator< TYPE > | gen, |
Callback && | c | ||
) |
Checks if any element satisfies a predicate.
TYPE | The element type. |
Callback | The predicate function type. |
gen | The generator to check. |
c | The existence predicate. |
Short-circuits on first true result. Returns false for empty generators.
Example:
Creates an any-match pipe operation.
F | The predicate function type. |
f | The existence predicate. |
Factory function for creating any-match operations.
SET original::collect | ( | coroutine::generator< TYPE > | gen | ) |
Collects generator elements into a set.
TYPE | The type of elements in the generator. |
SET | The set type to collect into (default: hashSet). |
gen | The generator to collect from. |
Transforms a generator sequence into a set container, removing duplicates and providing fast lookup capabilities.
Example:
Creates a count pipe operation.
Factory function for creating count operations that can be used with the pipe operator.
u_integer original::count | ( | coroutine::generator< TYPE > | gen | ) |
Counts total elements in a generator.
TYPE | The element type. |
gen | The generator to count. |
Consumes the generator and returns the total element count.
Example:
u_integer original::count | ( | coroutine::generator< TYPE > | gen, |
Callback && | c | ||
) |
Counts elements satisfying a predicate.
TYPE | The element type. |
Callback | The predicate function type. |
gen | The generator to count from. |
c | The counting predicate. |
Counts only elements for which the predicate returns true.
Example:
Creates a conditional count pipe operation.
F | The predicate function type. |
f | The counting predicate. |
Factory function for creating conditional count operations.
Creates an enumerate pipe operation.
Factory function for creating enumerate operations that can be used with the pipe operator.
coroutine::generator< couple< u_integer, TYPE > > original::enumerate | ( | coroutine::generator< TYPE > | gen | ) |
Enumerates elements of a generator with their indices.
TYPE | The type of elements in the generator. |
gen | The generator to enumerate. |
Creates a sequence of (index, value) pairs starting from index 0. Useful for tracking element positions during iteration.
Example:
coroutine::generator< TYPE > original::extract | ( | coroutine::generator< TYPE > | gen, |
Callback && | c | ||
) |
Extracts elements that do not satisfy a predicate.
TYPE | The element type. |
Callback | The predicate function type. |
gen | The source generator. |
c | The exclusion predicate. |
Opposite of filters() - excludes elements that match the predicate and includes all others.
Example:
Creates an extract pipe operation.
F | The predicate function type. |
f | The exclusion predicate. |
Factory function for creating extract operations that can be used with the pipe operator.
coroutine::generator< TYPE > original::filters | ( | coroutine::generator< TYPE > | gen, |
Callback && | c | ||
) |
Filters generator elements based on a predicate.
TYPE | The element type. |
Callback | The predicate function type. |
gen | The source generator. |
c | The filter predicate. |
Creates a new generator that only includes elements for which the predicate returns true.
Example:
Creates a filter pipe operation.
F | The predicate function type. |
f | The filter predicate. |
Factory function for creating filter operations that can be used with the pipe operator.
TYPE original::find | ( | coroutine::generator< TYPE > | gen, |
Callback && | c | ||
) |
Finds the first element satisfying a predicate.
TYPE | The element type. |
Callback | The predicate function type. |
gen | The generator to search. |
c | The search predicate. |
TYPE
if not found.Returns the first element that satisfies the predicate. If no element matches, returns a default-constructed value of type TYPE
.
Example:
Creates an element-finding pipe operation.
F | The predicate function type. |
f | The search predicate. |
Factory function for creating element-finding operations.
Creates a flatten pipe operation.
T | The first element type in couples. |
U | The second element type in couples. |
Factory function for creating flatten operations that can be used with the pipe operator.
coroutine::generator< T > original::flatten | ( | coroutine::generator< couple< T, U > > | gen | ) |
Flattens a generator of couples into a single generator.
T | Type of first element in couples. |
U | Type of second element in couples (must be convertible to T). |
gen | Generator of couples. |
Converts a generator of pairs into a flat sequence by yielding both elements of each couple in order.
Example:
filterStream< T > original::group | ( | const filter< T > & | f | ) |
Create grouped filterStream from single filter.
T | Element type |
f | Filter to group |
Enables future operator precedence modifications
filterStream< T > original::group | ( | const filterStream< T > & | ofs | ) |
Create grouped filterStream from existing stream.
T | Element type |
ofs | filterStream to group |
Use instead of parentheses for explicit precedence control
coroutine::generator< T > original::join | ( | coroutine::generator< T > | gen1, |
coroutine::generator< U > | gen2 | ||
) |
Joins two generators of compatible types.
T | Type of first generator and result elements. |
U | Type of second generator elements (must be convertible to T). |
gen1 | First generator. |
gen2 | Second generator. |
Concatenates two generators, converting elements from the second generator to the type of the first.
Example:
Creates a join pipe operation.
T | The target element type. |
U | The source element type. |
gen2 | The generator to join with. |
Factory function for creating join operations that can be used with the pipe operator.
SERIAL< TYPE > original::list | ( | coroutine::generator< TYPE > | gen | ) |
Collects generator elements into a list container.
TYPE | The type of elements in the generator. |
SERIAL | The list container type (default: vector). |
gen | The generator to collect from. |
Converts a generator sequence into a concrete list container, preserving element order and allowing random access.
Example:
Creates a new ownerPtr managing a dynamically allocated object.
T | Type of object to create and manage |
DEL | Deleter policy type (default: deleter<T>) |
Args | Argument types for object construction |
args | Arguments to forward to T's constructor |
Creates a new ownerPtr managing a dynamically allocated array.
T | Type of array elements to create |
DEL | Deleter policy type (default: deleter<T[]>) |
Args | Argument types for array element initialization |
size | Number of elements in the array |
args | Arguments to forward to each element's constructor |
Creates an index sequence of given length.
NUM | Length of the sequence to create |
Creates a new strongPtr managing a shared object.
T | Type of object to create and manage |
DEL | Deleter policy type (default: deleter<T>) |
Args | Argument types for object construction |
args | Arguments to forward to T's constructor |
The object will be destroyed when all strong references are released
Creates a new strongPtr managing a shared array.
T | Type of array elements to create |
DEL | Deleter policy type (default: deleter<T[]>) |
Args | Argument types for array element initialization |
size | Number of elements in the array |
args | Arguments to forward to each element's constructor |
The array will be destroyed when all strong references are released
Creates a tuple from a couple (copy version)
F_TYPE | First element type |
S_TYPE | Second element type |
cp | Couple to convert to tuple |
Creates a tuple from a couple (move version)
F_TYPE | First element type |
S_TYPE | Second element type |
cp | Couple to convert to tuple |
Returns the larger of two given values.
TYPE | The type of the input values. |
a | The first input value. |
b | The second input value. |
a
and b
.This function compares the two values a
and b
, and returns the value that is greater. Uses operator> for comparison.
Returns the smaller of two given values.
TYPE | The type of the input values. |
a | The first input value. |
b | The second input value. |
a
and b
.This function compares the two values a
and b
, and returns the value that is smaller. Uses operator< for comparison.
bool original::none | ( | coroutine::generator< TYPE > | gen, |
Callback && | c | ||
) |
Checks if no elements satisfy a predicate.
TYPE | The element type. |
Callback | The predicate function type. |
gen | The generator to check. |
c | The exclusion predicate. |
Short-circuits on first true result. Returns true for empty generators.
Example:
auto original::none | ( | F && | f | ) |
Creates a none-match pipe operation.
F | The predicate function type. |
f | The exclusion predicate. |
Factory function for creating none-match operations.
filterStream< T > original::operator! | ( | const filter< T > & | f | ) |
Create negated filterStream from filter.
T | Element type |
f | Filter to negate |
filterStream< T > original::operator! | ( | const filterStream< T > & | ofs | ) |
Create negated filterStream from existing stream.
T | Element type |
ofs | filterStream to negate |
Inequality comparison with nullptr.
T | Managed object type |
DER | CRTP derived class type |
DEL | Deleter policy type |
ptr | autoPtr to compare |
null | nullptr_t to compare against |
bool original::operator!= | ( | const iterator< T > & | l_it, |
const iterator< T > & | r_it | ||
) |
Inequality comparison operator for iterators.
T | The type of elements the iterator traverses. |
l_it | Left-hand side iterator. |
r_it | Right-hand side iterator. |
equalPtr
for optimal constant-time comparison. Inequality comparison with nullptr (reversed operands)
T | Managed object type |
DER | CRTP derived class type |
DEL | Deleter policy type |
ptr | autoPtr to compare |
null | nullptr_t to compare against |
filterStream< T > original::operator&& | ( | const filter< T > & | f, |
const filterStream< T > & | ofs | ||
) |
AND operator between filter and filterStream.
T | Element type |
f | Filter operand |
ofs | filterStream operand |
filterStream< T > original::operator&& | ( | const filter< T > & | f1, |
const filter< T > & | f2 | ||
) |
Create AND filterStream from two filters.
T | Element type |
f1 | First filter operand |
f2 | Second filter operand |
filterStream< T > original::operator&& | ( | const filterStream< T > & | ofs, |
const filter< T > & | f | ||
) |
AND operator between filterStream and filter.
T | Element type |
ofs | filterStream operand |
f | Filter operand |
|
inline |
d | Duration to multiply |
factor | Multiplication factor |
|
inline |
factor | Multiplication factor |
d | Duration to multiply |
auto original::operator+ | ( | const iterator< T > & | it, |
integer | steps | ||
) | -> iterator< T > * |
Adds a number of steps to the iterator's current position and returns a new iterator.
T | The type of the elements the iterator will traverse. |
it | The iterator to move. |
steps | The number of steps to move forward. |
This operator does not modify the original iterator, but creates a new one that is advanced by steps
positions.
|
inline |
d | Duration to add |
t | UTCTime |
|
inline |
lhs | Left operand |
rhs | Right operand |
|
inline |
p | Time point |
d | Duration to add |
|
inline |
t | UTCTime |
d | Duration to add |
|
related |
Creates new stream by prefixing existing stream.
Creates new stream from transformation and existing stream.
T | Data type |
t | Transformation to prepend |
ots | Original stream |
|
related |
Creates new transformation stream from two transforms.
Creates new stream from two transformations.
T | Data type |
t1 | First transformation |
t2 | Second transformation |
auto original::operator- | ( | const iterator< T > & | it, |
integer | steps | ||
) | -> iterator< T > * |
Subtracts a number of steps from the iterator's current position and returns a new iterator.
T | The type of the elements the iterator will traverse. |
it | The iterator to move. |
steps | The number of steps to move backward. |
This operator does not modify the original iterator, but creates a new one that is moved backward by steps
positions.
|
inline |
d | Duration to negate |
|
inline |
lhs | Left operand |
rhs | Right operand |
|
inline |
lhs | Left operand |
rhs | Right operand |
|
inline |
p | Time point |
d | Duration to subtract |
|
inline |
lhs | Left operand |
rhs | Right operand |
|
inline |
t | UTCTime |
d | Duration to subtract |
|
inline |
d | Duration to divide |
factor | Division factor |
|
inline |
lhs | Left operand |
rhs | Right operand |
|
inline |
Stream insertion operator for printable objects.
os | Output stream |
p | Printable object |
Enables direct streaming of printable objects to output streams. Uses the object's toString(false) method to generate the output without trailing newline.
bool original::operator== | ( | const iterator< T > & | l_it, |
const iterator< T > & | r_it | ||
) |
Equality comparison operator for iterators.
T | The type of elements the iterator traverses. |
l_it | Left-hand side iterator. |
r_it | Right-hand side iterator. |
equalPtr
for optimal constant-time comparison. Equality comparison with nullptr (reversed operands)
T | Managed object type |
DER | CRTP derived class type |
DEL | Deleter policy type |
ptr | autoPtr to compare |
null | nullptr_t to compare against |
auto original::operator| | ( | async::future< T > | f, |
Callback && | c | ||
) |
Pipe operator for chaining asynchronous computations.
This operator dynamically attaches a new callback to an already running future. The callback will be executed once the asynchronous result becomes available. Unlike a lazy pipeline builder, this version modifies the execution flow immediately.
T | Result type of the future |
Callback | Callable type, must accept T or T&& (depending on constness and value category) |
f | Source future containing the asynchronous result |
c | Callback function to process the result |
auto original::operator| | ( | async::future< void > | f, |
Callback && | c | ||
) |
Pipe operator specialization for future<void>
This operator dynamically attaches a new callback to an already running future<void>. The callback will be executed once the asynchronous task completes. This is suitable for chaining tasks that do not produce a value. Execution is immediate, not deferred.
Callback | Callable type, must accept no arguments |
f | Source future<void> representing completion of an asynchronous task |
c | Callback function to execute after completion |
auto original::operator| | ( | async::promise< T, Callback1 > | p, |
Callback2 && | c | ||
) |
Lazy pipe operator for chaining promise computations.
This operator creates a lazy composition of promises, where the computation is only executed when the resulting promise is run. Unlike the dynamic pipe operator for futures, this creates a new promise that combines both computations without immediate execution.
The pipeline is built lazily - no computation occurs until run() is called on the resulting promise. This allows for building complex computation graphs without immediate execution overhead.
T | Result type of the source promise |
Callback1 | Type of the source promise's computation |
Callback2 | Type of the continuation callback |
p | Source promise containing the initial computation |
c | Callback function to process the result of the source promise |
auto original::operator| | ( | async::promise< void, Callback1 > | p, |
Callback2 && | c | ||
) |
Lazy pipe operator specialization for promise<void>
This operator creates a lazy composition of void-returning promises, where the first computation completes before the second begins. The pipeline executes sequentially but only when the resulting promise is run.
Useful for building sequences of side-effectful operations that need to execute in order but don't produce values.
Callback1 | Type of the source promise's computation |
Callback2 | Type of the continuation callback |
p | Source promise containing the initial void computation |
c | Callback function to execute after the source promise completes |
auto original::operator| | ( | async::sharedFuture< T > | sf, |
Callback && | c | ||
) |
Pipe operator for chaining computations on sharedFuture.
This operator dynamically attaches a new callback to an already running sharedFuture. Unlike lazy task builders, the continuation is immediately scheduled to run once the sharedFuture produces a value. This makes it possible to share and extend asynchronous results across multiple consumers.
T | Result type of the sharedFuture |
Callback | Callable type, must accept T const& or T (depending on design) |
sf | Source sharedFuture containing the asynchronous result |
c | Callback function to process the result |
auto original::operator| | ( | async::sharedFuture< void > | sf, |
Callback && | c | ||
) |
Pipe operator specialization for sharedFuture<void>
This operator dynamically attaches a new callback to an already running sharedFuture<void>. The callback will be executed once the asynchronous task completes. Since sharedFuture can be copied, multiple consumers can each dynamically attach their own continuations.
Callback | Callable type, must accept no arguments |
sf | Source sharedFuture<void> representing completion of an asynchronous task |
c | Callback function to execute after completion |
auto original::operator| | ( | coroutine::generator< TYPE > | gen, |
genPipe< F > | p | ||
) |
Pipe operator for generator operations.
TYPE | The generator element type. |
F | The pipe operation type. |
gen | The source generator. |
p | The pipe operation to apply. |
Enables fluent chaining of generator operations using the | operator.
Example:
filterStream< T > original::operator|| | ( | const filter< T > & | f, |
const filterStream< T > & | ofs | ||
) |
OR operator between filter and filterStream.
T | Element type |
f | Filter operand |
ofs | filterStream operand |
filterStream< T > original::operator|| | ( | const filter< T > & | f1, |
const filter< T > & | f2 | ||
) |
Create OR filterStream from two filters.
T | Element type |
f1 | First filter operand |
f2 | Second filter operand |
filterStream< T > original::operator|| | ( | const filterStream< T > & | ofs, |
const filter< T > & | f | ||
) |
OR operator between filterStream and filter.
T | Element type |
ofs | filterStream operand |
f | Filter operand |
u_integer original::position | ( | coroutine::generator< TYPE > | gen, |
Callback && | c | ||
) |
Finds the position of the first element satisfying a predicate.
TYPE | The element type. |
Callback | The predicate function type. |
gen | The generator to search. |
c | The search predicate. |
Returns the 0-based index of the first element that satisfies the predicate. If no element matches, returns the total number of elements processed.
Example:
Creates a position-finding pipe operation.
F | The predicate function type. |
f | The search predicate. |
Factory function for creating position-finding operations.
Returns the result of raising a base to an exponent.
base | The base value. |
exp | The exponent value. |
base
raised to the power of exp
. valueError | If base is 0 and exp is less than or equal to 0. |
This function performs exponentiation by iterating exp
times and multiplying the base. If exp
is negative, it computes the reciprocal of the result. An exception is thrown if base
is 0 and exp
is non-positive.
coroutine::generator< INTEGER > original::rangesOf | ( | INTEGER | start, |
INTEGER | end, | ||
INTEGER | steps = 1 |
||
) |
Generates a sequence of integers from start
to end
(exclusive) with a given steps
.
This function returns a coroutine-based generator that yields integer values starting from start
, incrementing or decrementing by steps
, until end
is reached (exclusive). Supports both forward and backward iteration with positive and negative step sizes.
INTEGER | The integer type (defaults to int ). |
start | The starting value (inclusive). |
end | The ending value (exclusive). |
steps | The step size between values (default is 1). |
steps
is zero or the range is invalid (e.g., start > end with positive step), the generator will immediately complete without yielding any values. consteval auto original::reverseIndexSequenceImpl | ( | indexSequence< Indices... > | seq | ) |
Implementation detail for reversing an index sequence.
Indices | Sequence indices to reverse |
seq | The index sequence to reverse |
coroutine::generator< TYPE > original::skip | ( | coroutine::generator< TYPE > | gen, |
u_integer | n | ||
) |
Skips the first n elements of a generator.
TYPE | The element type. |
gen | The source generator. |
n | Number of elements to skip. |
Discards the first n elements and yields the remainder of the sequence.
Example:
Creates a skip pipe operation.
n | Number of elements to skip. |
Factory function for creating skip operations that can be used with the pipe operator.
coroutine::generator< TYPE > original::take | ( | coroutine::generator< TYPE > | gen, |
u_integer | n | ||
) |
Takes the first n elements from a generator.
TYPE | The element type. |
gen | The source generator. |
n | Number of elements to take. |
Limits the output to the first n elements of the input generator. Stops early if the input generator has fewer than n elements.
Example:
Creates a take pipe operation.
n | Number of elements to take. |
Factory function for creating take operations that can be used with the pipe operator.
auto original::transforms | ( | coroutine::generator< TYPE > | gen, |
Callback && | c | ||
) | -> coroutine::generator<std::invoke_result_t<Callback, TYPE>> |
Transforms generator elements using a callable.
TYPE | The input element type. |
Callback | The transformation function type. |
gen | The source generator. |
c | The transformation callable. |
Applies a transformation function to each element of the input generator, producing a new generator with the transformed values.
Example:
Creates a transform pipe operation.
F | The transformation function type. |
f | The transformation function. |
Factory function for creating transform operations that can be used with the pipe operator.
Example:
coroutine::generator< couple< T, U > > original::zip | ( | coroutine::generator< T > | gen1, |
coroutine::generator< U > | gen2 | ||
) |
Zips two generators into pairs.
T | Type of first generator elements. |
U | Type of second generator elements. |
gen1 | First generator. |
gen2 | Second generator. |
Pairs elements from two generators positionally. Stops when either generator is exhausted.
Example:
auto original::zipWith | ( | coroutine::generator< U > | gen2 | ) |
Creates a zipWith pipe operation.
U | The element type of the second generator. |
gen2 | The generator to zip with. |
Factory function for creating zip operations that can be used with the pipe operator.
|
constexpr |
The mathematical constant E (Euler's number).
This is the base of the natural logarithm, approximately equal to 2.71828. It is used in various mathematical, scientific, and engineering applications, particularly in exponential growth and decay models, as well as in complex analysis.
|
constexpr |
The mathematical constant PI (π).
This is the ratio of a circle's circumference to its diameter, approximately equal to 3.14159. It is used in geometry, trigonometry, and many other mathematical fields, especially when dealing with circular or spherical shapes.