Navigation
API > API/Runtime > API/Runtime/Core > API/Runtime/Core/Algo > API/Runtime/Core/Algo/Algo__IncludesBy
References
| Module | Core |
| Header | /Engine/Source/Runtime/Core/Public/Algo/Includes.h |
| Include | #include "Algo/Includes.h" |
namespace Algo
{
template<typename RangeTypeA, typename RangeTypeB, typename ProjectionType, typename SortPredicateType>
bool Algo::IncludesBy
(
RangeTypeA && RangeA,
RangeTypeB && RangeB,
ProjectionType Projection,
SortPredicateType SortPredicate
)
}
Remarks
Checks if one sorted contiguous container is a subsequence of another sorted contiguous container by comparing pairs of projected elements using a custom predicate. The subsequence does not need to be contiguous. True if RangeB is a subsequence of RangeA according to the comparison of projected elements using the provided predicate, false otherwise.
Parameters
| Name | Description |
|---|---|
| RangeA | Container of elements to search through. Must be already sorted by SortPredicate. |
| RangeB | Container of elements to search for. Must be already sorted by SortPredicate. |
| Projection | Projection to apply to the elements before comparing them. |
| SortPredicate | A binary predicate object, applied to the projection, used to specify if one element should precede another. |