pub enum DataType {
}
Expand description
Defines a DataType enum that is optimized for execution (and transferral along the wire).
Variants§
Any
Any type is accepted.
Void
No type is accepted.
Numeric
Allows both integers and reals.
Addable
Allows integers, reals and strings.
Callable
Allows any callable object.
NonVoid
Allows everything but Void
Boolean
Only Boolean values are accepted (i.e., true or false, 1 or 0, yes or no, etc).
Integer
Only Integral values are accepted (i.e., non-decimal numbers)
Real
Only Real values are accepted (i.e., decimal numbers)
String
Only String values are accepted (i.e., arrays of characters)
Semver
Only Semantic versioning are accepted (i.e., major.minor.patch)
Array
Arrays (i.e., a memory area divided into homogeneous types).
Function
Functions (i.e., executable pieces of code). Contains both the types (and arity) of its arguments and the return type.
Class
Classes (i.e., a memory area divided into heterogeneous types). The usize indexes the signature into the Workflow’s global buffers.
Data
An externally represented dataset. The string is its identifier.
IntermediateResult
An externally represented dataset but one that may also be generated by functions.
Implementations§
source§impl DataType
impl DataType
sourcepub fn allowed_by(&self, other: &Self) -> bool
pub fn allowed_by(&self, other: &Self) -> bool
Returns if this DataType is the same or at least targeted of the given one.
A common use-case for this function is checking return types, where the return type would be the given one.
§Arguments
allowed
: The DataType that describes what is allowed.
§Returns
Whether or not this DataType “is the same” as the other one.
Trait Implementations§
source§impl<'de> Deserialize<'de> for DataType
impl<'de> Deserialize<'de> for DataType
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
impl Eq for DataType
impl StructuralPartialEq for DataType
Auto Trait Implementations§
impl Freeze for DataType
impl RefUnwindSafe for DataType
impl Send for DataType
impl Sync for DataType
impl Unpin for DataType
impl UnwindSafe for DataType
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§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)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<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> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T
in a tonic::Request