pub enum Builtin {
Length,
Count,
IsEmpty,
IsNull,
Contains,
StartsWith,
EndsWith,
AsInt,
AsFloat,
AsString,
AsBool,
}Expand description
The closed catalog of pure builtins (§Fase 70.c). All are total + pure.
Collection/string predicates only; the predicate-taking folds (any/all/
none) need lambdas and are deferred, as are sum/min/max and in/??.
Variants§
Length
.length — collection element count, or character count of a string.
Count
.count — alias of length.
IsEmpty
.is_empty — length == 0.
IsNull
.is_null — the value is absent / empty / null.
Contains
.contains(x) — array membership, or string substring.
StartsWith
.starts_with(s) — string prefix test.
EndsWith
.ends_with(s) — string suffix test.
AsInt
§Fase 73.c — .as_int — honest coercion of a Json value to an
integer. Fail-closed: a value that is not a JSON integer resolves
to null, never a panic (doctrine open_data_is_total).
AsFloat
§Fase 73.c — .as_float — honest coercion to a float (an integer
widens; anything else → null).
AsString
§Fase 73.c — .as_string — honest coercion to a string (only a
JSON string succeeds; a number / bool / null → null).
AsBool
§Fase 73.c — .as_bool — honest coercion to a boolean (only a
JSON bool succeeds; anything else → null).
Implementations§
Trait Implementations§
impl Copy for Builtin
impl Eq for Builtin
impl StructuralPartialEq for Builtin
Auto Trait Implementations§
impl Freeze for Builtin
impl RefUnwindSafe for Builtin
impl Send for Builtin
impl Sync for Builtin
impl Unpin for Builtin
impl UnsafeUnpin for Builtin
impl UnwindSafe for Builtin
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more