structs_column_view.hpp
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2022-2023, NVIDIA CORPORATION.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 #pragma once
17 
18 #include <cudf/column/column.hpp>
20 #include <cudf/utilities/default_stream.hpp>
21 
22 #include <rmm/cuda_stream_view.hpp>
23 
29 namespace cudf {
30 
41  public:
42  // Foundation members:
45  ~structs_column_view() = default;
58 
64  explicit structs_column_view(column_view const& col);
65 
71  [[nodiscard]] column_view parent() const;
72 
79  using column_view::offset;
80  using column_view::size;
81 
98  int index, rmm::cuda_stream_view stream = cudf::get_default_stream()) const;
99 }; // class structs_column_view; // end of group
101 } // namespace cudf
cudf::structs_column_view
Given a column view of struct type, an instance of this class provides a wrapper on this compound col...
Definition: structs_column_view.hpp:40
cudf::column_view::child_begin
auto child_begin() const noexcept
Returns iterator to the beginning of the ordered sequence of child column-views.
Definition: column_view.hpp:402
column.hpp
Class definition for cudf::column.
cudf::structs_column_view::structs_column_view
structs_column_view(column_view const &col)
Construct a new structs column view object from a column view.
cudf::column_view::num_children
size_type num_children() const noexcept
Returns the number of child columns.
Definition: column_view.hpp:395
cudf::column_view
A non-owning, immutable view of device data as a column of elements, some of which may be null as ind...
Definition: column_view.hpp:313
cudf::detail::column_view_base::offset
size_type offset() const noexcept
Returns the index of the first element relative to the base memory allocation, i.e....
Definition: column_view.hpp:225
rmm::cuda_stream_view
cudf::structs_column_view::structs_column_view
structs_column_view(structs_column_view const &)=default
Copy constructor.
cudf::column_view::child_end
auto child_end() const noexcept
Returns iterator to the end of the ordered sequence of child column-views.
Definition: column_view.hpp:409
cudf::structs_column_view::parent
column_view parent() const
Returns the parent column.
cudf::detail::column_view_base::null_count
size_type null_count() const
Returns the count of null elements.
Definition: column_view.hpp:165
cudf::structs_column_view::operator=
structs_column_view & operator=(structs_column_view &&)=default
Move assignment operator.
cudf::detail::column_view_base::has_nulls
bool has_nulls() const
Indicates if the column contains null elements, i.e., null_count() > 0
Definition: column_view.hpp:190
cudf::structs_column_view::structs_column_view
structs_column_view(structs_column_view &&)=default
Move constructor.
cudf
cuDF interfaces
Definition: aggregation.hpp:34
cudf::get_default_stream
rmm::cuda_stream_view const get_default_stream()
Get the current default stream.
cudf::detail::column_view_base::size
size_type size() const noexcept
Returns the number of elements in the column.
Definition: column_view.hpp:133
cudf::structs_column_view::get_sliced_child
column_view get_sliced_child(int index, rmm::cuda_stream_view stream=cudf::get_default_stream()) const
Returns the internal child column, applying any offset from the root.
column_view.hpp
column view class definitions
cudf::structs_column_view::operator=
structs_column_view & operator=(structs_column_view const &)=default
Copy assignment operator.
cudf::detail::column_view_base::null_mask
bitmask_type const * null_mask() const noexcept
Returns raw pointer to the underlying bitmask allocation.
Definition: column_view.hpp:217