xtd
1.0.0
Toggle main menu visibility
Loading...
Searching...
No Matches
xtd.core
include
xtd
ranges
views
to_array_view.hpp
Go to the documentation of this file.
1
4
#pragma once
5
6
#include "
../../linq/enumerable.hpp
"
7
#include "
../../istringable.hpp
"
8
#include "
../../iterable.hpp
"
9
#include "
../../string.hpp
"
10
#include "
../../views/views.hpp
"
11
13
namespace
xtd
{
15
namespace
ranges
{
17
namespace
views
{
37
class
to_array_view
{
38
public
:
40
45
template
<xtd::iterable iterable_t>
46
auto
operator()
(iterable_t&& source)
const
{
return
xtd::linq::enumerable::from
(std::forward<iterable_t>(source)).to_array();}
47
59
template
<xtd::iterable iterable_t>
60
friend
auto
operator |
(iterable_t&& source,
const
to_array_view
& view) {
return
view(std::forward<iterable_t>(source));}
62
};
63
}
64
}
65
}
xtd::linq::enumerable::from
static auto from(source_t &&source) noexcept
Returns the input typed as xtd::collections::generic::ienumerable <type_t>.
xtd::ranges::views::to_array_view
The xtd::ranges::views::to_array_view class is used to convert a sequence to an array.
Definition
to_array_view.hpp:37
xtd::ranges::views::to_array_view::operator()
auto operator()(iterable_t &&source) const
Converts a sequence of values to an array.
Definition
to_array_view.hpp:46
xtd::ranges::views::to_array_view::operator|
friend auto operator|(iterable_t &&source, const to_array_view &view)
Applies a filter on the given range using the pipe operator.
Definition
to_array_view.hpp:60
istringable.hpp
Contains xtd::istringable interface.
iterable.hpp
Contains xtd::iterable concept.
enumerable.hpp
Contains xtd::linq::enumerable <type_t> class.
xtd::ranges::views
The view namesapce contains range views, lightweight objects that indirectly represent iterable seque...
Definition
distinct.hpp:20
xtd::ranges
The ranges namespace is an extension and generalization of the xtd::linq that makes them more powerfu...
Definition
distinct.hpp:18
xtd
The xtd namespace contains all fundamental classes to access Hardware, Os, System,...
Definition
abstract_object.hpp:8
string.hpp
Contains xtd::string alias.
views.hpp
Contains xtd::views alias namespace.
Generated on
for xtd by
Gammasoft
. All rights reserved.