Home
libcudf
cucim
cudf-java
cudf
cugraph
cuml
cuproj
cusignal
cuspatial
cuxfilter
dask-cuda
dask-cudf
kvikio
libcudf
libcugraph
libcuml
libcuproj
libcuspatial
libkvikio
librmm
raft
rapids-cmake
rmm
legacy (23.06)
nightly (23.10)
stable (23.08)
legacy (23.06)
include
cudf
strings
char_types
char_types_enum.hpp
Go to the documentation of this file.
1
/*
2
* Copyright (c) 2019-2022, 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 <cstdint>
19
#include <type_traits>
20
21
namespace
cudf
{
22
namespace
strings {
38
enum
string_character_types
: uint32_t {
39
DECIMAL
= 1 << 0,
40
NUMERIC
= 1 << 1,
41
DIGIT
= 1 << 2,
42
ALPHA
= 1 << 3,
43
SPACE
= 1 << 4,
44
UPPER
= 1 << 5,
45
LOWER
= 1 << 6,
46
ALPHANUM
=
DECIMAL
|
NUMERIC
|
DIGIT
|
ALPHA
,
47
CASE_TYPES
=
UPPER
|
LOWER
,
48
ALL_TYPES
=
ALPHANUM
|
CASE_TYPES
|
SPACE
49
};
50
58
constexpr
string_character_types
operator|
(
string_character_types
lhs,
string_character_types
rhs)
59
{
60
return
static_cast<
string_character_types
>
(
61
static_cast<
std::underlying_type_t<string_character_types>
>
(lhs) |
62
static_cast<
std::underlying_type_t<string_character_types>
>
(rhs));
63
}
64
72
constexpr
string_character_types
&
operator|=
(
string_character_types
& lhs,
73
string_character_types
rhs)
74
{
75
lhs =
static_cast<
string_character_types
>
(
76
static_cast<
std::underlying_type_t<string_character_types>
>
(lhs) |
77
static_cast<
std::underlying_type_t<string_character_types>
>
(rhs));
78
return
lhs;
79
}
80
// end of doxygen group
82
}
// namespace strings
83
}
// namespace cudf
cudf::strings::NUMERIC
@ NUMERIC
all numeric characters
Definition:
char_types_enum.hpp:40
cudf::strings::LOWER
@ LOWER
all lower case characters
Definition:
char_types_enum.hpp:45
cudf::strings::CASE_TYPES
@ CASE_TYPES
all case-able characters
Definition:
char_types_enum.hpp:47
cudf::strings::operator|=
constexpr string_character_types & operator|=(string_character_types &lhs, string_character_types rhs)
Compound assignment OR operator for combining string_character_types.
Definition:
char_types_enum.hpp:72
cudf::strings::SPACE
@ SPACE
all space characters
Definition:
char_types_enum.hpp:43
cudf::strings::ALPHANUM
@ ALPHANUM
all alphanumeric characters
Definition:
char_types_enum.hpp:46
cudf::strings::DIGIT
@ DIGIT
all digit characters
Definition:
char_types_enum.hpp:41
cudf::strings::ALL_TYPES
@ ALL_TYPES
all character types
Definition:
char_types_enum.hpp:48
cudf
cuDF interfaces
Definition:
aggregation.hpp:34
cudf::strings::UPPER
@ UPPER
all upper case characters
Definition:
char_types_enum.hpp:44
cudf::strings::operator|
constexpr string_character_types operator|(string_character_types lhs, string_character_types rhs)
OR operator for combining string_character_types.
Definition:
char_types_enum.hpp:58
cudf::strings::ALPHA
@ ALPHA
all alphabetic characters
Definition:
char_types_enum.hpp:42
cudf::strings::DECIMAL
@ DECIMAL
all decimal characters
Definition:
char_types_enum.hpp:39
cudf::strings::string_character_types
string_character_types
Character type values. These types can be or'd to check for any combination of types.
Definition:
char_types_enum.hpp:38
Generated by
1.8.20