#[repr(u8)]pub enum Kind {
Show 27 variants
Null = 0,
Bool = 1,
Int = 2,
Uint = 3,
Double = 4,
String = 5,
Bytes = 6,
Struct = 7,
Duration = 8,
Timestamp = 9,
List = 10,
Map = 11,
Unknown = 12,
Type = 13,
Error = 14,
Any = 15,
Dyn = 16,
Opaque = 17,
BoolWrapper = 18,
IntWrapper = 19,
UintWrapper = 20,
DoubleWrapper = 21,
StringWrapper = 22,
BytesWrapper = 23,
TypeParam = 24,
Function = 25,
Enum = 26,
}
Expand description
Represents the fundamental type categories in CEL.
This enum corresponds to the Kind
type in CEL-CPP and serves as the base type
classification system for CEL values and types. It provides a unified way to
represent both value types and type kinds in the CEL type system.
§Variants
§Primitive Types
Null
- The null value typeBool
- Boolean valuesInt
- 64-bit signed integersUint
- 64-bit unsigned integersDouble
- 64-bit floating-point numbersString
- UTF-8 encoded stringsBytes
- Raw byte sequences
§Complex Types
Struct
- Structured data typesList
- Homogeneous listsMap
- Key-value mappings
§Protocol Buffer Types
Duration
- Time duration valuesTimestamp
- Point-in-time valuesBoolWrapper
- Protocol buffer bool wrapperIntWrapper
- Protocol buffer int64 wrapperUintWrapper
- Protocol buffer uint64 wrapperDoubleWrapper
- Protocol buffer double wrapperStringWrapper
- Protocol buffer string wrapperBytesWrapper
- Protocol buffer bytes wrapper
§Special Types
Unknown
- Type not yet determinedType
- Type of a type (meta-type)Error
- Error typeAny
- Dynamic type that can hold any valueDyn
- Dynamic type for runtime type checkingOpaque
- Custom opaque typesTypeParam
- Type parameter in generic typesFunction
- Function typeEnum
- Enumeration type
Variants§
Null = 0
Bool = 1
Int = 2
Uint = 3
Double = 4
String = 5
Bytes = 6
Struct = 7
Duration = 8
Timestamp = 9
List = 10
Map = 11
Unknown = 12
Type = 13
Error = 14
Any = 15
Dyn = 16
Opaque = 17
BoolWrapper = 18
IntWrapper = 19
UintWrapper = 20
DoubleWrapper = 21
StringWrapper = 22
BytesWrapper = 23
TypeParam = 24
Function = 25
Enum = 26
Implementations§
Source§impl Kind
impl Kind
pub fn is_type_kind(&self) -> bool
pub fn is_value_kind(&self) -> bool
Trait Implementations§
Source§impl ExternType for Kind
impl ExternType for Kind
Source§impl SpanElement for Kind
impl SpanElement for Kind
impl Copy for Kind
impl Eq for Kind
impl StructuralPartialEq for Kind
Auto Trait Implementations§
impl Freeze for Kind
impl RefUnwindSafe for Kind
impl Send for Kind
impl Sync for Kind
impl Unpin for Kind
impl UnwindSafe for Kind
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more