Language:
Discover
By Skill Level
By Category

Algo

Choose your OS:

Filters

Classes

Name

Description

Public struct

TLess

Public struct

TPlus

TPlus specifically takes const T& and returns T.

Functions

Name Description

Public function

T

 

Algo::Accumulate

(
    const A& Input,
    T Init,
    OpT Op
)

Sums a range by successively applying Op.

the result of summing all the elements of Input

Public function

T

 

Algo::Accumulate

(
    const A& Input,
    T Init
)

Sums a range.

the result of summing all the elements of Input

Public function

bool

 

Algo::AllOf

(
    const RangeType& Range,
    ProjectionType Projection
)

Checks if every projection of the elements in the range is truthy.

Public function

bool

 

Algo::AllOf

(
    const RangeType& Range
)

Checks if every element in the range is truthy.

Public function

bool

 

Algo::AnyOf

(
    const RangeType& Range
)

Checks if any element in the range is truthy.

Public function

bool

 

Algo::AnyOf

(
    const RangeType& Range,
    ProjectionType Projection
)

Checks if any projection of the elements in the range is truthy.

Public function

int32

 

Algo::BinarySearch

(
    RangeType& Range,
    const ValueType& Value
)

Public function

int32

 

Algo::BinarySearch

(
    RangeType& Range,
    const ValueType& Value,
    SortPredicateType SortPredicate
)

Returns index to the first found element matching a value in a range, the range must be sorted by <

Public function

int32

 

Algo::BinarySearchBy

(
    RangeType& Range,
    const ValueType& Value,
    ProjectionType Projection
)

Public function

int32

 

Algo::BinarySearchBy

(
    RangeType& Range,
    const ValueType& Value,
    ProjectionType Projection,
    SortPredicateType SortPredicate
)

Returns index to the first found element with projected value matching Value in a range, the range must be sorted by predicate

Public function

bool

 

Algo::CompareByPredicate

(
    const InT& InputA,
    const InT& InputB,
    PredicateT Predicate
)

Compares entries in the container using a user-defined predicate container

Public function

void

 

Algo::Copy

(
    const InT& Input,
    OutT& Output
)

Copies a range into a container

Public function

void

 

Algo::CopyIf

(
    const InT& Input,
    OutT& Output,
    PredicateT Predicate
)

Conditionally copies a range into a container

Public function

SIZE_T

 

Algo::Count

(
    const InT& Input,
    const ValueT& InValue
)

Counts elements of a range that equal the supplied value

Public function

SIZE_T

 

Algo::CountIf

(
    const InT& Input,
    PredicateT Predicate
)

Counts elements of a range that match a given predicate

Public function

auto

 

Algo::Find

(
    RangeType& Range,
    const ValueType& Value
)

Returns a pointer to the first element in the range which is equal to the given value.

Public function

auto

 

Algo::FindBy

(
    RangeType& Range,
    const ValueType& Value,
    ProjectionType Proj
)

Returns a pointer to the first element in the range whose projection is equal to the given value.

Public function

auto

 

Algo::FindByPredicate

(
    RangeType& Range,
    PredicateType Pred
)

Returns a pointer to the first element in the range which matches the predicate.

Public function

int32

 

Algo::FindSortedStringCaseInsensitive

(
    const TCHAR * Str,
    const TCHAR *const (&) SortedAr...
)

Finds a string in an array of sorted strings, by case-insensitive search, by using binary subdivision of the array.

Public function

void

 

Algo::Heapify

(
    RangeType& Range,
    PredicateType Predicate
)

Builds an implicit min-heap from a range of elements.

Public function

void

 

Algo::Heapify

(
    RangeType& Range
)

Builds an implicit min-heap from a range of elements.

Public function

void

 

Algo::HeapifyBy

(
    RangeType& Range,
    ProjectionType Projection,
    PredicateType Predicate
)

Builds an implicit min-heap from a range of elements.

Public function

void

 

Algo::HeapifyBy

(
    RangeType& Range,
    ProjectionType Projection
)

Builds an implicit min-heap from a range of elements.

Public function

void

 

Algo::HeapSort

(
    RangeType& Range
)

Performs heap sort on the elements. Assumes < operator is defined for the element type.

Public function

void

 

Algo::HeapSort

(
    RangeType& Range,
    PredicateType Predicate
)

Performs heap sort on the elements.

Public function

void

 

Algo::HeapSortBy

(
    RangeType& Range,
    ProjectionType Projection,
    PredicateType Predicate
)

Performs heap sort on the elements.

Public function

void

 

Algo::HeapSortBy

(
    RangeType& Range,
    ProjectionType Projection
)

Performs heap sort on the elements. Assumes < operator is defined for the projected element type.

Public function

void

 

Algo::IntroSort

(
    RangeType& Range
)

Sort a range of elements using its operator<. The sort is unstable.

Public function

void

 

Algo::IntroSort

(
    RangeType& Range,
    PredicateType Predicate
)

Sort a range of elements using a user-defined predicate class. The sort is unstable.

Public function

void

 

Algo::IntroSortBy

(
    RangeType& Range,
    ProjectionType Projection,
    PredicateType Predicate
)

Sort a range of elements by a projection using a user-defined predicate class.

Public function

void

 

Algo::IntroSortBy

(
    RangeType& Range,
    ProjectionType Projection
)

Sort a range of elements by a projection using the projection's operator<. The sort is unstable.

Public function

bool

 

Algo::IsHeap

(
    RangeType& Range,
    PredicateType Predicate
)

Verifies that the range is a min-heap (parent <= child)

returns true if the range is a min-heap

Public function

bool

 

Algo::IsHeap

(
    RangeType& Range
)

Verifies that the range is a min-heap (parent <= child).

Public function

bool

 

Algo::IsHeapBy

(
    RangeType& Range,
    ProjectionType Projection,
    PredicateType Predicate
)

Verifies that the range is a min-heap (parent <= child)

returns true if the range is a min-heap

Public function

bool

 

Algo::IsHeapBy

(
    RangeType& Range,
    ProjectionType Projection
)

Verifies that the range is a min-heap (parent <= child).

Public function

bool

 

Algo::IsSorted

(
    const T* Array,
    int32 ArraySize
)

Tests if a range is sorted by its element type's operator<.

Public function

bool

 

Algo::IsSorted

(
    const T* Array,
    int32 ArraySize,
    PredType Pred
)

Tests if a range is sorted by a user-defined predicate.

Public function

bool

 

Algo::IsSorted

(
    const RangeType& Range,
    PredType Pred
)

Tests if a range is sorted by a user-defined predicate.

Public function

bool

 

Algo::IsSorted

(
    const RangeType& Range
)

Tests if a range is sorted by its element type's operator<.

Public function

bool

 

Algo::IsSortedBy

(
    const RangeType& Range,
    ProjectionType Projection,
    PredType Pred
)

Tests if a range is sorted by a projection of the element type, using a user-defined predicate on the projection.

Public function

bool

 

Algo::IsSortedBy

(
    const RangeType& Range,
    ProjectionType Projection
)

Tests if a range is sorted by a projection of the element type, using the projection's operator<.

Public function

void

 

Algo::LegacySort

(
    RangeType& Range
)

Sort a range of elements using its operator<.

Public function

void

 

Algo::LegacySort

(
    RangeType& Range,
    PredicateType Pred
)

Sort a range of elements using a user-defined predicate class.

Public function

void

 

Algo::LegacySortBy

(
    RangeType& Range,
    ProjectionType Proj
)

Sort a range of elements by a projection using the projection's operator<.

Public function

void

 

Algo::LegacySortBy

(
    RangeType& Range,
    ProjectionType Proj,
    PredicateType Pred
)

Sort a range of elements by a projection using a user-defined predicate class.

Public function

int32

 

Algo::LevenshteinDistance

(
    const RangeAType& RangeA,
    const RangeBType& RangeB
)

LevenshteinDistance return the number of edit operation we need to transform RangeA to RangeB.

Public function

int32

 

Algo::LowerBound

(
    RangeType& Range,
    const ValueType& Value,
    SortPredicateType SortPredicate
)

Performs binary search, resulting in position of the first element >= Value using predicate

Public function

int32

 

Algo::LowerBound

(
    RangeType& Range,
    const ValueType& Value
)

Public function

int32

 

Algo::LowerBoundBy

(
    RangeType& Range,
    const ValueType& Value,
    ProjectionType Projection,
    SortPredicateType SortPredicate
)

Performs binary search, resulting in position of the first element with projected value >= Value using predicate

Public function

int32

 

Algo::LowerBoundBy

(
    RangeType& Range,
    const ValueType& Value,
    ProjectionType Projection
)

Public function

auto

 

Algo::MaxElement

(
    RangeType& Range,
    ComparatorType Comp
)

Returns a pointer to the maximum element in a range with a user-defined binary comparator.

Public function

auto

 

Algo::MaxElement

(
    RangeType& Range
)

Returns a pointer to the maximum element in a range.

Public function

auto

 

Algo::MaxElementBy

(
    RangeType& Range,
    ProjectionType Proj,
    ComparatorType Comp
)

Returns a pointer to the maximum element in a range with a user-defined binary comparator.

Public function

auto

 

Algo::MaxElementBy

(
    RangeType& Range,
    ProjectionType Proj
)

Returns a pointer to the maximum element in a range with a user-defined binary comparator.

Public function

auto

 

Algo::MinElement

(
    RangeType& Range,
    ComparatorType Comp
)

Returns a pointer to the minimum element in a range with a user-defined binary comparator.

Public function

auto

 

Algo::MinElement

(
    RangeType& Range
)

Returns a pointer to the minimum element in a range.

Public function

auto

 

Algo::MinElementBy

(
    RangeType& Range,
    ProjectionType Proj,
    ComparatorType Comp
)

Returns a pointer to the minimum element in a range with a user-defined binary comparator.

Public function

auto

 

Algo::MinElementBy

(
    RangeType& Range,
    ProjectionType Proj
)

Returns a pointer to the minimum element in a range with a user-defined binary comparator.

Public function

bool

 

Algo::NoneOf

(
    const RangeType& Range,
    ProjectionType Projection
)

Checks if no projection of the elements in the range is truthy.

Public function

bool

 

Algo::NoneOf

(
    const RangeType& Range
)

Checks if no element in the range is truthy.

true if no element is truthy, false otherwise.

Public function

int32

 

Algo::Partition

(
    T* Elements,
    const int32 Num,
    const UnaryPredicate& Predicate
)

Rearranges the elements so that all the elements for which Predicate returns true precede all those for which it returns false.

Public function

void

 

Algo::Reverse

(
    T* Array,
    int32 ArraySize
)

Reverses a range

Public function

void

 

Algo::Reverse

(
    T(&) Array
)

Reverses a range

Public function

void

 

Algo::Reverse

(
    ContainerType& Container
)

Reverses a range

Public function

void

 

Algo::Sort

(
    RangeType& Range,
    PredicateType Pred
)

Sort a range of elements using a user-defined predicate class. The sort is unstable.

Public function

void

 

Algo::Sort

(
    RangeType& Range
)

Sort a range of elements using its operator<. The sort is unstable.

Public function

void

 

Algo::SortBy

(
    RangeType& Range,
    ProjectionType Proj,
    PredicateType Pred
)

Sort a range of elements by a projection using a user-defined predicate class.

Public function

void

 

Algo::SortBy

(
    RangeType& Range,
    ProjectionType Proj
)

Sort a range of elements by a projection using the projection's operator<. The sort is unstable.

Public function

void

 

Algo::Transform

(
    const InT& Input,
    OutT& Output,
    TransformT Trans
)

Applies a transform to a range and stores the results into a container

Public function

T

 

Algo::TransformAccumulate

(
    const A& Input,
    MapT MapOp,
    T Init,
    OpT Op
)

Sums a range by applying MapOp to each element, and then summing the results.

Public function

T

 

Algo::TransformAccumulate

(
    const A& Input,
    MapT MapOp,
    T Init
)

Sums a range by applying MapOp to each element, and then summing the results.

Public function

void

 

Algo::TransformIf

(
    const InT& Input,
    OutT& Output,
    PredicateT Predicate,
    TransformT Trans
)

Conditionally applies a transform to a range and stores the results into a container

Public function

int32

 

Algo::UpperBound

(
    RangeType& Range,
    const ValueType& Value,
    SortPredicateType SortPredicate
)

Performs binary search, resulting in position of the first element > Value using predicate

Public function

int32

 

Algo::UpperBound

(
    RangeType& Range,
    const ValueType& Value
)

Public function

int32

 

Algo::UpperBoundBy

(
    RangeType& Range,
    const ValueType& Value,
    ProjectionType Projection,
    SortPredicateType SortPredicate
)

Performs binary search, resulting in position of the first element with projected value > Value using predicate

Public function

int32

 

Algo::UpperBoundBy

(
    RangeType& Range,
    const ValueType& Value,
    ProjectionType Projection
)

Public function

TRangePointe ...

 

AlgoImpl::FindBy

(
    RangeType& Range,
    const ValueType& Value,
    ProjectionType Proj
)

Public function

TRangePointe ...

 

AlgoImpl::FindByPredicate

(
    RangeType& Range,
    PredicateType Pred
)

Public function

void

 

AlgoImpl::IntroSortInternal

(
    T* First,
    SIZE_T Num,
    ProjectionType Projection,
    PredicateType Predicate
)

Implementation of an introspective sort.

Public function

bool

 

AlgoImpl::IsHeapInternal

(
    RangeValueType* Heap,
    SIZE_T Num,
    ProjectionType Projection,
    PredicateType Predicate
)

Verifies that the range is a min-heap (parent <= child) This is the internal function used by IsHeap overrides.

Public function

bool

 

AlgoImpl::IsSortedBy

(
    const T* Range,
    int32 RangeSize,
    ProjectionType Proj,
    PredType Pred
)

Public function

void

 

AlgoImpl::LegacySortInternal

(
    T* First,
    int32 Num,
    ProjectionType Projection,
    PredicateType Predicate
)

Sort elements using user defined predicate class.

Public function

SIZE_T

 

AlgoImpl::LowerBoundInternal

(
    RangeValueType* First,
    const SIZE_T Num,
    const PredicateValueType& Value,
    ProjectionType Projection,
    SortPredicateType SortPredicate
)

Performs binary search, resulting in position of the first element >= Value

Public function

TRangePointe ...

 

AlgoImpl::MaxElementBy

(
    RangeType& Range,
    ProjectionType Proj,
    PredicateType Pred
)

Public function

TRangePointe ...

 

AlgoImpl::MinElementBy

(
    RangeType& Range,
    ProjectionType Proj,
    PredicateType Pred
)

Public function

void

 

AlgoImpl::Reverse

(
    T* Array,
    int32 ArraySize
)

Public function

SIZE_T

 

AlgoImpl::UpperBoundInternal

(
    RangeValueType* First,
    const SIZE_T Num,
    const PredicateValueType& Value,
    ProjectionType Projection,
    SortPredicateType SortPredicate
)

Performs binary search, resulting in position of the first element that is larger than the given value