10#define __XTD_STD_INTERNAL__
12#undef __XTD_STD_INTERNAL__
13#define __XTD_CORE_INTERNAL__
17#undef __XTD_CORE_INTERNAL__
39template<
typename type_t>
40struct __opaque_xtd_linq_enumerable_collection__;
41template<
typename type_t,
typename param_t>
42struct __opaque_xtd_linq_lazy_enumerable__;
50 template<
typename type_t>
52 template<
typename type_t>
81 template<
typename type_t>
85 template<
typename type_t>
89 template<
typename type_t>
93 template<
typename type_t>
97 template<
typename key_t,
typename value_t>
112 template<xtd::iterable source_t, xtd::func_callable<xtd::iterable_value_type<source_t>, xtd::iterable_value_type<source_t>, xtd::iterable_value_type<source_t>> func_t>
124 template<
typename accumulate_t, xtd::iterable source_t, xtd::func_callable<accumulate_t, accumulate_t, xtd::iterable_value_type<source_t>> func_t>
125 [[nodiscard]]
static auto aggregate(source_t&& source, accumulate_t&& seed, func_t&&
func) -> accumulate_t;
138 template<
typename result_t,
typename accumulate_t, xtd::iterable source_t, xtd::func_callable<accumulate_t, accumulate_t, xtd::iterable_value_type<source_t>> func_t, xtd::func_callable<result_t, accumulate_t> result_selector_t>
139 [[nodiscard]]
static auto aggregate(source_t&& source, accumulate_t&& seed, func_t&&
func, result_selector_t&& result_selector) -> result_t;
149 template<xtd::iterable source_t, xtd::predicate_callable<xtd::iterable_value_type<source_t>> predicate_t>
150 [[nodiscard]]
static auto all(source_t&& source, predicate_t&&
predicate) -> bool;
160 template<xtd::iterable source_t>
161 [[nodiscard]]
static auto any(source_t&& source)
noexcept -> bool;
170 template<xtd::iterable source_t, xtd::predicate_callable<xtd::iterable_value_type<source_t>> predicate_t>
171 [[nodiscard]]
static auto any(source_t&& source, predicate_t&&
predicate) -> bool;
181 template<xtd::iterable source_t>
192 template<xtd::iterable source_t>
201 template<xtd::iterable source_t>
210 template<xtd::iterable source_t>
219 template<
typename value_t>
229 template<std::forward_iterator iterator_t>
239 template<std::forward_iterator iterator_t>
249 template<
typename value_t, xtd::usize length>
259 template<
typename value_t, xtd::usize length>
263 template<xtd::usize size_>
265 template<xtd::usize size_>
267 template<
typename value_t,
typename container_t>
269 template<
typename value_t,
typename container_t>
271 template<
typename value_t,
typename container_t>
273 template<
typename value_t,
typename container_t>
275 template<
typename value_t,
typename container_t>
277 template<
typename value_t,
typename container_t>
285 template<xtd::iterable source_t>
292 template<xtd::iterable source_t>
294 [[nodiscard]]
static auto average(source_t&& source) -> double;
299 template<xtd::iterable source_t>
306 template<xtd::iterable source_t>
308 [[nodiscard]]
static auto average(source_t&& source) -> double;
313 template<xtd::iterable source_t>
315 [[nodiscard]]
static auto average(source_t&& source) -> double;
320 template<xtd::iterable source_t>
326 template<xtd::iterable source_t>
332 template<xtd::iterable source_t>
338 template<xtd::iterable source_t>
344 template<xtd::iterable source_t>
355 template<
typename result_t, xtd::iterable source_t>
365 template<xtd::iterable source_t>
373 template<xtd::iterable first_t,xtd::iterable second_t>
381 template<xtd::iterable source_t>
389 template<xtd::iterable source_t>
397 template<xtd::iterable source_t, xtd::func_callable<
bool, xtd::iterable_value_type<source_t>, xtd::iterable_value_type<source_t>> equater_t>
407 template<xtd::iterable source_t>
417 template<xtd::iterable source_t, xtd::predicate_callable<xtd::iterable_value_type<source_t>> predicate_t>
424 template<xtd::iterable source_t>
436 template<
typename key_t, xtd::iterable source_t, xtd::callable<key_t, xtd::iterable_value_type<source_t>> key_selector_t>
448 template<
typename key_t, xtd::iterable source_t, xtd::callable<key_t, xtd::iterable_value_type<source_t>> key_selector_t>
461 template<
typename key_t, xtd::iterable source_t, xtd::callable<key_t, xtd::iterable_value_type<source_t>> key_selector_t, xtd::callable<
bool, key_t, key_t> key_equater_t>
471 template<xtd::iterable source_t>
481 template<xtd::iterable source_t>
488 template<xtd::iterable source_t>
494 template<xtd::iterable source_t>
501 template<xtd::iterable source_t, xtd::func_callable<
bool, xtd::iterable_value_type<source_t>, xtd::iterable_value_type<source_t>> equater_t>
510 template<xtd::iterable source_t, xtd::predicate_callable<xtd::iterable_value_type<source_t>> prediacte_t>
517 template<xtd::iterable source_t, xtd::predicate_callable<xtd::iterable_value_type<source_t>> prediacte_t>
524 template<xtd::iterable source_t>
530 template<xtd::iterable source_t>
542 template<xtd::iterable source_t>
543 [[nodiscard]]
static auto from(source_t&& source)
noexcept;
552 template<xtd::iterable source_t>
562 template<xtd::iterable source_t>
572 template<
typename value_t>
585 template<std::forward_iterator iterator_t>
596 template<std::forward_iterator iterator_t>
607 template<
typename value_t, xtd::usize length>
618 template<
typename value_t, xtd::usize length>
622 template<xtd::usize size_>
624 template<xtd::usize size_>
626 template<
typename value_t,
typename container_t>
628 template<
typename value_t,
typename container_t>
630 template<
typename value_t,
typename container_t>
632 template<
typename value_t,
typename container_t>
634 template<
typename value_t,
typename container_t>
636 template<
typename value_t,
typename container_t>
643 template<xtd::iterable source_t>
650 template<xtd::iterable source_t, xtd::callable<xtd::iterable_value_type<source_t>, xtd::iterable_value_type<source_t>> selector_t>
657 template<
typename result_t, xtd::iterable source_t, xtd::callable<result_t, xtd::iterable_value_type<source_t>> selector_t>
659 [[nodiscard]]
static auto max(source_t&& source, selector_t&& selector) -> result_t;
664 template<xtd::iterable source_t>
671 template<xtd::iterable source_t, xtd::callable<xtd::iterable_value_type<source_t>, xtd::iterable_value_type<source_t>> selector_t>
678 template<
typename result_t, xtd::iterable source_t, xtd::callable<result_t, xtd::iterable_value_type<source_t>> selector_t>
680 [[nodiscard]]
static auto min(source_t&& source, selector_t&& selector) -> result_t;
685 template<xtd::iterable source_t>
691 template<xtd::iterable source_t>
698 template<xtd::iterable source_t, xtd::func_callable<
bool, xtd::iterable_value_type<source_t>, xtd::iterable_value_type<source_t>> lesser_t>
708 template<
typename key_t, xtd::iterable source_t, xtd::callable<key_t, xtd::iterable_value_type<source_t>> key_selector_t>
718 template<xtd::iterable source_t, xtd::callable<xtd::iterable_value_type<source_t>, xtd::iterable_value_type<source_t>> key_selector_t>
728 template<
typename key_t, xtd::iterable source_t, xtd::callable<key_t, xtd::iterable_value_type<source_t>> key_selector_t>
738 template<xtd::iterable source_t, xtd::callable<xtd::iterable_value_type<source_t>, xtd::iterable_value_type<source_t>> key_selector_t>
748 template<xtd::
integer
integer_t>
758 template<xtd::
integer
integer_t>
766 template<xtd::
integer
integer_t>
778 template<
typename result_t, xtd::iterable source_t>
789 template<xtd::iterable source_t>
796 template<xtd::forward_iterable source_t>
803 template<xtd::iterable source_t>
813 template<xtd::iterable source_t>
820 template<xtd::iterable source_t>
827 template<xtd::iterable source_t>
837 template<xtd::iterable source_t>
849 template<
typename source_t>
861 template<
typename source_t>
875 template<xtd::iterable source_t>
880 template<
typename type_t>
881 struct enumerable_holder {
882 enumerable_holder(
const type_t& value);
884 enumerable_holder(type_t&& value)
requires std::movable<type_t>;
889 std::optional<type_t> value_;
893 template<
typename...>
894 static inline constexpr bool always_false_v =
false;
896 template<
typename source_t>
897 requires(
requires (
const xtd::raw_type<source_t>& source) {{source.size()} -> std::convertible_to<std::size_t>;})
899 template<
typename source_t>
900 requires(!
requires (
const xtd::raw_type<source_t>& source) {{source.size()} -> std::convertible_to<std::size_t>;})
901 [[nodiscard]]
static auto invoke_take_with_range(source_t&& source,
const xtd::range&
range) -> xtd::collections::generic::enumerable_generator<xtd::iterable_value_type<source_t>>;
903 template<
typename predicate_t,
typename value_t>
904 [[nodiscard]]
static constexpr auto invoke_predicate_with_optional_index(predicate_t&&
predicate, value_t&& value,
xtd::usize index) -> bool;
906 template<
typename result_t,
typename selector_t,
typename value_t>
907 [[nodiscard]]
static auto invoke_selector_with_optional_index(selector_t&& selector, value_t&& value,
xtd::usize index) -> result_t;
Contains xtd::callable concept.
Provides methods for creating, manipulating, searching, and sorting arrays, thereby serving as the ba...
Definition array.hpp:64
Represents an enumerable generator that supports deferred, lazy iteration over a collection of a spec...
Definition enumerable_generator.hpp:44
Exposes a method that compares two objects.
Definition icomparer.hpp:30
Exposes the enumerator, which supports a simple iteration over a collection of a specified type.
Definition ienumerable.hpp:40
Defines methods to support the comparison of objects for equality.
Definition iequality_comparer.hpp:34
Represents a strongly typed list of objects that can be accessed by index. Provides methods to search...
Definition list.hpp:82
Provides a set of static methods for querying objects that implement ienumerable <type_t>.
Definition enumerable_.hpp:75
static auto chunk(source_t &&source, xtd::usize size) -> xtd::collections::generic::enumerable_generator< xtd::array< xtd::iterable_value_type< source_t > > >
Splits the elements of a sequence into chunks of size at most size.
static auto order_by_descending(source_t &&source, key_selector_t &&key_selector) -> xtd::collections::generic::enumerable_generator< xtd::iterable_value_type< source_t > >
Sorts the elements of a sequence in descending order according to a key.
static auto order(source_t &&source, lesser_t &&lesser) -> xtd::collections::generic::enumerable_generator< xtd::iterable_value_type< source_t > >
Sorts the elements of a sequence in ascending order.
static auto range(integer_t start, integer_t count) -> xtd::collections::generic::enumerable_generator< integer_t >
Generates a sequence of integral numbers within a specified range.
static auto order_by(source_t &&source, key_selector_t &&key_selector) -> xtd::collections::generic::enumerable_generator< xtd::iterable_value_type< source_t > >
Sorts the elements of a sequence in ascending order according to a key.
static auto skip_while(source_t &&source, auto &&predicate) -> xtd::collections::generic::enumerable_generator< xtd::iterable_value_type< source_t > >
Bypasses elements in a sequence as long as a specified condition is true and then returns the remaini...
static auto order_by_descending(source_t &&source, key_selector_t &&key_selector) -> xtd::collections::generic::enumerable_generator< xtd::iterable_value_type< source_t > >
Sorts the elements of a sequence in descending order according to a key.
static auto max(source_t &&source, selector_t &&selector) -> xtd::iterable_value_type< source_t >
Returns the maximum value in a sequence of xtd::numeric values.
typename xtd::collections::generic::ienumerable< type_t > ienumerable
Represents the ienumerable value type.
Definition enumerable_.hpp:90
typename xtd::collections::generic::enumerator< type_t > enumerator
Represents the enumerator value type.
Definition enumerable_.hpp:82
static auto distinct(source_t &&source) noexcept -> xtd::collections::generic::enumerable_generator< xtd::iterable_value_type< source_t > >
Returns distinct elements from a sequence by using the default equality comparer to compare values.
static auto from(std::initializer_list< value_t > source) noexcept -> xtd::collections::generic::enumerable_generator< value_t >
Returns the input typed as xtd::collections::generic::ienumerable <type_t>.
static auto concat(first_t &&first, second_t &&second) noexcept -> xtd::collections::generic::enumerable_generator< xtd::iterable_value_type< first_t > >
Concatenates two sequences.
static auto first_or_default(source_t &&source, prediacte_t &&predicate, xtd::iterable_value_type< source_t > &&default_value) noexcept -> xtd::iterable_value_type< source_t >
Returns the first element of the sequence that satisfies a condition, or a specified default value if...
typename xtd::collections::generic::iequality_comparer< type_t > iequality_comparer
Represents the ienumerable value type.
Definition enumerable_.hpp:86
static auto min(source_t &&source) -> xtd::iterable_value_type< source_t >
Returns the minimum value in a sequence of xtd::numeric values.
static auto count_by(source_t &&source, key_selector_t &&key_selector, const iequality_comparer< key_t > &key_comparer) noexcept -> xtd::collections::generic::enumerable_generator< xtd::collections::generic::key_value_pair< key_t, xtd::usize > >
Returns the count of elements in the source sequence grouped by key.
static auto as_enumerable(iterator_t first, iterator_t last) noexcept -> xtd::collections::generic::enumerable_generator< typename std::decay< decltype(*first)>::type >
Returns the input typed as xtd::collections::generic::ienumerable <type_t>.
typename xtd::collections::generic::list< type_t > list
Represents the list value type.
Definition enumerable_.hpp:94
static auto as_enumerable(value_t(&array)[length]) noexcept -> xtd::collections::generic::enumerable_generator< value_t >
Returns the input typed as xtd::collections::generic::ienumerable <type_t>.
static auto select(source_t &&source, auto &&selector) -> xtd::collections::generic::enumerable_generator< result_t >
Projects each element of a sequence into a new form.
static auto default_if_empty(source_t &&source) noexcept -> xtd::collections::generic::enumerable_generator< xtd::iterable_value_type< source_t > >
Returns the elements of the specified sequence or the type parameter's default value in a singleton c...
static auto contains(source_t &&source, const xtd::iterable_value_type< source_t > &value) noexcept -> bool
Determines whether a sequence contains a specified element by using the default equality comparer.
static auto aggregate(source_t &&source, accumulate_t &&seed, func_t &&func) -> accumulate_t
Applies an accumulator function over a sequence. The specified seed value is used as the initial accu...
static auto as_enumerable(const value_t(&array)[length]) noexcept -> xtd::collections::generic::enumerable_generator< value_t >
Returns the input typed as xtd::collections::generic::ienumerable <type_t>.
static auto aggregate(source_t &&source, accumulate_t &&seed, func_t &&func, result_selector_t &&result_selector) -> result_t
Applies an accumulator function over a sequence. The specified seed value is used as the initial accu...
static auto take(source_t &&source, xtd::usize count) -> xtd::collections::generic::enumerable_generator< xtd::iterable_value_type< source_t > >
Returns a specified number of contiguous elements from the start of a sequence.
static auto average(source_t &&source) -> double
Computes the average of a sequence of xtd::int64 values.
static auto average(source_t &&source) -> xtd::optional< double >
Computes the average of a sequence of optional xtd::int64 values.
static auto as_enumerable(const source_t &source) noexcept -> xtd::collections::generic::enumerable_generator< xtd::iterable_value_type< source_t > >
Returns the input typed as xtd::collections::generic::ienumerable <type_t>.
static auto average(source_t &&source) -> xtd::optional< double >
Computes the average of a sequence of optional double values.
static auto count_by(source_t &&source, key_selector_t &&key_selector) noexcept -> xtd::collections::generic::enumerable_generator< xtd::collections::generic::key_value_pair< key_t, xtd::usize > >
Returns the count of elements in the source sequence grouped by key.
static auto first_or_default(source_t &&source, xtd::iterable_value_type< source_t > &&default_value) noexcept -> xtd::iterable_value_type< source_t >
Returns the first element of the sequence that satisfies a condition or a default value if no such el...
static auto from(iterator_t iterator, xtd::usize length) noexcept -> xtd::collections::generic::enumerable_generator< typename std::decay< decltype(*iterator)>::type >
Returns the input typed as xtd::collections::generic::ienumerable <type_t>.
static auto all(source_t &&source, predicate_t &&predicate) -> bool
Determines whether all elements of a sequence satisfy a condition.
static auto average(source_t &&source) -> xtd::optional< xtd::decimal >
Computes the average of a sequence of optional xtd::decimal values.
static auto as_enumerable(iterator_t iterator, xtd::usize length) noexcept -> xtd::collections::generic::enumerable_generator< typename std::decay< decltype(*iterator)>::type >
Returns the input typed as xtd::collections::generic::ienumerable <type_t>.
static auto distinct(source_t &&source, equater_t &&equater) noexcept -> xtd::collections::generic::enumerable_generator< xtd::iterable_value_type< source_t > >
Returns distinct elements from a sequence by using a specified xtd::collections::generic::iequality_c...
static auto average(source_t &&source) -> xtd::optional< xtd::single >
Computes the average of a sequence of optional float values.
static auto order(source_t &&source, const xtd::collections::generic::icomparer< xtd::iterable_value_type< source_t > > &comparer) -> xtd::collections::generic::enumerable_generator< xtd::iterable_value_type< source_t > >
Sorts the elements of a sequence in ascending order.
static auto from(source_t &&source) noexcept
Returns the input typed as xtd::collections::generic::ienumerable <type_t>.
static auto max(source_t &&source, selector_t &&selector) -> result_t
Returns the maximum value in a sequence of xtd::numeric values.
static auto shuffle(source_t &&source) -> xtd::collections::generic::enumerable_generator< xtd::iterable_value_type< source_t > >
Shuffles the order of the elements of a sequence.
Definition random.hpp:277
static auto contains(source_t &&source, const xtd::iterable_value_type< source_t > &value, equater_t &&equater) noexcept -> bool
Determines whether a sequence contains a specified element by using a specified equality comparer.
static auto order(source_t &&source) -> xtd::collections::generic::enumerable_generator< xtd::iterable_value_type< source_t > >
Sorts the elements of a sequence in ascending order.
static auto cast(source_t &&source) -> xtd::collections::generic::enumerable_generator< result_t >
Casts the elements of an xtd::collections::generic::ienumerable to the specified type.
static auto where(source_t &&source, auto &&predicate) -> xtd::collections::generic::enumerable_generator< xtd::iterable_value_type< source_t > >
Filters a sequence of values based on a predicate.
static auto aggregate(source_t &&source, func_t &&func) -> xtd::iterable_value_type< source_t >
Applies an accumulator function over a sequence.
static auto first_or_default(source_t &&source, prediacte_t &&predicate) noexcept -> xtd::iterable_value_type< source_t >
Returns the first element of the sequence that satisfies a condition or a default value if no such el...
static auto from(iterator_t first, iterator_t last) noexcept -> xtd::collections::generic::enumerable_generator< typename std::decay< decltype(*first)>::type >
Returns the input typed as xtd::collections::generic::ienumerable <type_t>.
static auto as_enumerable(source_t &&source) noexcept
Returns the input typed as xtd::collections::generic::ienumerable <type_t>.
static auto average(source_t &&source) -> xtd::decimal
Computes the average of a sequence of xtd::decimal values.
static auto as_enumerable(source_t &source) noexcept -> xtd::collections::generic::enumerable_generator< xtd::iterable_value_type< source_t > >
Returns the input typed as xtd::collections::generic::ienumerable <type_t>.
static auto any(source_t &&source, predicate_t &&predicate) -> bool
Determines whether any element of a sequence satisfies a condition.
static auto select(source_t &&source, auto &&selector) -> xtd::collections::generic::enumerable_generator< xtd::iterable_value_type< source_t > >
Projects each element of a sequence into a new form by incorporating the element's index.
static auto from(const value_t(&array)[length]) noexcept -> xtd::collections::generic::enumerable_generator< value_t >
Returns the input typed as xtd::collections::generic::ienumerable <type_t>.
static auto min(source_t &&source, selector_t &&selector) -> xtd::iterable_value_type< source_t >
Returns the minimum value in a sequence of xtd::numeric values.
static auto from(value_t(&array)[length]) noexcept -> xtd::collections::generic::enumerable_generator< value_t >
Returns the input typed as xtd::collections::generic::ienumerable <type_t>.
static auto count(source_t &&source, predicate_t &&predicate) noexcept -> xtd::usize
Returns a number that represents how many elements in the specified sequence satisfy a condition.
static auto from(const source_t &source) noexcept -> xtd::collections::generic::enumerable_generator< xtd::iterable_value_type< source_t > >
Returns the input typed as xtd::collections::generic::ienumerable <type_t>.
static auto contains(source_t &&source, const xtd::iterable_value_type< source_t > &value, const iequality_comparer< xtd::iterable_value_type< source_t > > &comparer) noexcept -> bool
Determines whether a sequence contains a specified element by using a specified equality comparer.
static auto average(source_t &&source) -> double
Computes the average of a sequence of double values.
static auto to_array(const ienumerable< source_t > &source)
Creates a xtd::array <type_t> from an xtd::collections::generic::ienumerable <type_t>.
static auto append(source_t &&source, xtd::iterable_value_type< source_t > &&element) noexcept -> xtd::collections::generic::enumerable_generator< xtd::iterable_value_type< source_t > >
Appends a value to the end of the sequence.
static auto range(integer_t start, integer_t count, integer_t step) -> xtd::collections::generic::enumerable_generator< integer_t >
Generates a sequence of integral numbers within a specified range and step.
static auto as_enumerable(std::initializer_list< value_t > source) noexcept -> xtd::collections::generic::enumerable_generator< value_t >
Returns the input typed as xtd::collections::generic::ienumerable <type_t>.
xtd::collections::generic::key_value_pair< key_t, value_t > key_value_pair
Represents the key value pair value type.
Definition enumerable_.hpp:98
static auto order_by(source_t &&source, key_selector_t &&key_selector) -> xtd::collections::generic::enumerable_generator< xtd::iterable_value_type< source_t > >
Sorts the elements of a sequence in ascending order according to a key.
static auto min(source_t &&source, selector_t &&selector) -> result_t
Returns the minimum value in a sequence of xtd::numeric values.
static auto count(source_t &&source) noexcept -> xtd::usize
Returns the number of elements in a sequence.
static auto range(integer_t count) -> xtd::collections::generic::enumerable_generator< integer_t >
Generates a sequence of integral numbers within a specified range.
static auto first_or_default(source_t &&source) noexcept -> xtd::iterable_value_type< source_t >
Returns the first element of the sequence that satisfies a condition or a default value if no such el...
static auto default_if_empty(source_t &&source, const xtd::iterable_value_type< source_t > &default_value) noexcept -> xtd::collections::generic::enumerable_generator< xtd::iterable_value_type< source_t > >
Returns the elements of the specified sequence or the specified value in a singleton collection if th...
static auto skip(source_t &&source, xtd::usize count) -> xtd::collections::generic::enumerable_generator< xtd::iterable_value_type< source_t > >
Bypasses a specified number of elements in a sequence and then returns the remaining elements.
static auto from(source_t &source) noexcept -> xtd::collections::generic::enumerable_generator< xtd::iterable_value_type< source_t > >
Returns the input typed as xtd::collections::generic::ienumerable <type_t>.
static auto distinct(source_t &&source, const iequality_comparer< source_t > &comparer) noexcept -> xtd::collections::generic::enumerable_generator< xtd::iterable_value_type< source_t > >
Returns distinct elements from a sequence by using a specified xtd::collections::generic::iequality_c...
static auto count(source_t &&source, xtd::iterable_value_type< source_t > &&value) noexcept -> xtd::usize
Returns the number of elements with the specified value.
static auto max(source_t &&source) -> xtd::iterable_value_type< source_t >
Returns the maximum value in a sequence of xtd::numeric values.
static auto take(source_t &&source, const xtd::range &range) -> xtd::collections::generic::enumerable_generator< xtd::iterable_value_type< source_t > >
Returns a specified number of contiguous elements from the start of a sequence.
static auto take_while(source_t &&source, auto &&predicate) -> xtd::collections::generic::enumerable_generator< xtd::iterable_value_type< source_t > >
Returns elements from a sequence as long as a specified condition is true, and then skips the remaini...
static auto any(source_t &&source) noexcept -> bool
Determines whether a sequence contains any elements.
static auto count_by(source_t &&source, key_selector_t &&key_selector, key_equater_t &&key_equater) noexcept -> xtd::collections::generic::enumerable_generator< xtd::collections::generic::key_value_pair< key_t, xtd::usize > >
Returns the count of elements in the source sequence grouped by key.
static auto to_list(const ienumerable< source_t > &source)
Creates a xtd::collections::generic::list <type_t> from an xtd::collections::generic::ienumerable <ty...
static auto average(source_t &&source) -> xtd::single
Computes the average of a sequence of float values.
static auto average(source_t &&source) -> xtd::optional< double >
Computes the average of a sequence of optional xtd::int32 values.
static auto average(source_t &&source) -> double
Computes the average of a sequence of xtd::int32 values.
Represents a range that has start and end indexes.
Definition range.hpp:28
Definition numeric.hpp:12
Definition real_decimal.hpp:13
Definition real_double.hpp:13
Definition real_single.hpp:13
Definition signed_integer_32.hpp:13
Definition signed_integer_64.hpp:14
Contains xtd::decimal type.
Contains xtd::collections::generic::equality_comparer <type_t> class.
Contains xtd::func_callable concept.
Contains xtd::collections::generic::comparer <type_t> class.
Contains xtd::collections::generic::enumerator <type_t> class.
xtd::raw_type< decltype(*std::begin(std::declval< iterable_t & >()))> iterable_value_type
Represents the orward iterable value type.
Definition iterable_value_type.hpp:29
xtd::delegate< result_t(arguments_t... arguments)> func
Represents a delegate that has variables parameters and returns a value of the type specified by the ...
Definition func.hpp:27
#define static_
This keyword is use to represent a static object. A static object can't be instantiated (constructors...
Definition static.hpp:38
std::type_info type
Stores information about a type.
Definition type.hpp:23
long double decimal
Represents a decimal-precision floating-point number.
Definition decimal.hpp:23
std::optional< type_t > optional
Represents the optional alias on std::optional.
Definition optional.hpp:26
std::size_t usize
Represents an unsigned size of any object in bytes.
Definition usize.hpp:22
float single
Represents a single-precision floating-point number.
Definition single.hpp:23
std::remove_cvref_t< value_t > raw_type
Represents a raw type alias equivalent to std::remove_cvref_t<value_t>.
Definition raw_type.hpp:25
xtd::func< bool, type_t > predicate
Represents a delegate that defines a set of criteria and determines whether the specified object meet...
Definition predicate.hpp:16
Contains xtd::iequatable interface.
Contains xtd::int32 type.
Contains xtd::int64 type.
Contains xtd::integer concept.
Contains xtd::iterable concept.
Contains xtd::iterable_value_type alias.
Contains xtd::collections::generic::helpers::lesser struct.
The xtd::collections::generic namespace contains interfaces and classes that define generic collectio...
Definition comparer.hpp:16
Provides classes and interfaces that support queries that use Language-Integrated Query (LINQ).
Definition enumerable_.hpp:58
The xtd namespace contains all fundamental classes to access Hardware, Os, System,...
Definition abstract_object.hpp:8
const xtd::collections::generic::helpers::wrap_pointer_iterator< pointer > iterator
Represents the iterator of read_only_span value type.
Definition read_only_span.hpp:74
auto first() const -> read_only_span< type_t, count >
Obtains a subspan consisting of the first count elements of the sequence.
Definition read_only_span.hpp:262
auto last() const -> read_only_span< type_t, count >
Obtains a subspan consisting of the last N elements of the sequence.
Definition read_only_span.hpp:287
constexpr auto length() const noexcept -> size_type
Returns the length of the current read_only_span.
Definition read_only_span.hpp:226
constexpr auto size() const noexcept -> size_type
Returns the number of elements.
Definition read_only_span.hpp:230
Contains xtd::numeric concept.
Contains xtd::optional type.
Contains xtd::predicate_callable concept.
Contains xtd::collections::generic::helpers::raw_array class.
Contains xtd::static_object class.
Supports a simple iteration over a generic collection.
Definition enumerator.hpp:39
Defines a key/value pair that can be set or retrieved.
Definition key_value_pair.hpp:37
Contains xtd::usize type.