20 #include <cuda_runtime.h>
29 namespace CUDF_EXPORT
cudf {
57 [[nodiscard]] __device__
inline size_type length()
const;
78 using difference_type = ptrdiff_t;
82 using iterator_category = std::input_iterator_tag;
104 [[nodiscard]] __device__
inline size_type position()
const;
105 [[nodiscard]] __device__
inline size_type byte_offset()
const;
158 [[nodiscard]] __device__
inline int compare(
string_view const& str)
const;
173 __device__
inline int compare(
char const* str,
size_type bytes)
const;
344 : _data(data), _bytes(bytes), _length(UNKNOWN_STRING_LENGTH)
402 template <
bool forward>
403 __device__
inline size_type find_impl(
char const* str,
一个非拥有、不可变的设备数据视图,它是表示 UTF-8 的变长字符数组...
CUDF_HOST_DEVICE size_type size_bytes() const
返回此字符串中的字节数。
string_view & operator=(string_view const &)=default
复制赋值运算符。
CUDF_HOST_DEVICE string_view()
默认构造函数表示一个空字符串。
CUDF_HOST_DEVICE bool empty() const
如果字符串没有字符则返回 true。
string_view(string_view &&)=default
移动构造函数。
const_iterator end() const
返回指向此字符串末尾之后的新迭代器。
CUDF_HOST_DEVICE string_view(char const *data, size_type bytes)
从现有设备字符数组创建实例。
string_view & operator=(string_view &&)=default
移动赋值运算符。
CUDF_HOST_DEVICE char const * data() const
返回指向内部设备数组的指针。
const_iterator begin() const
返回指向此字符串开头的新迭代器。
string_view(string_view const &)=default
复制构造函数。
bool operator==(polymorphic_allocator< T > const &lhs, polymorphic_allocator< U > const &rhs)
bool operator!=(polymorphic_allocator< T > const &lhs, polymorphic_allocator< U > const &rhs)
CUDF_HOST_DEVICE fixed_point< Rep1, Rad1 > operator-(fixed_point< Rep1, Rad1 > const &lhs, fixed_point< Rep1, Rad1 > const &rhs)
CUDF_HOST_DEVICE bool operator>=(fixed_point< Rep1, Rad1 > const &lhs, fixed_point< Rep1, Rad1 > const &rhs)
CUDF_HOST_DEVICE bool operator<=(fixed_point< Rep1, Rad1 > const &lhs, fixed_point< Rep1, Rad1 > const &rhs)
CUDF_HOST_DEVICE fixed_point< Rep1, Rad1 > operator*(fixed_point< Rep1, Rad1 > const &lhs, fixed_point< Rep1, Rad1 > const &rhs)
CUDF_HOST_DEVICE bool operator>(fixed_point< Rep1, Rad1 > const &lhs, fixed_point< Rep1, Rad1 > const &rhs)
CUDF_HOST_DEVICE fixed_point< Rep1, Rad1 > operator+(fixed_point< Rep1, Rad1 > const &lhs, fixed_point< Rep1, Rad1 > const &rhs)
CUDF_HOST_DEVICE bool operator<(fixed_point< Rep1, Rad1 > const &lhs, fixed_point< Rep1, Rad1 > const &rhs)
std::unique_ptr< column > rfind(strings_column_view const &input, string_scalar const &target, size_type start=0, size_type stop=-1, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref())
返回一个字符位置值列,其中从 ... 开始搜索时首次找到目标字符串
std::unique_ptr< column > find(strings_column_view const &input, string_scalar const &target, size_type start=0, size_type stop=-1, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref())
返回一个字符位置值列,其中在每个字符串中首次找到目标字符串...
int32_t size_type
用于列和表的行索引类型。
uint32_t char_utf8
UTF-8 字符为 1-4 字节。
#define CUDF_HOST_DEVICE
表示函数或方法可在主机和设备上使用。