pub struct Input { /* private fields */ }
Expand description
An Input to a [RuntimeFunction]
Implementations§
source§impl Input
impl Input
sourcepub fn new(
array_order: i32,
generic: bool,
initializer: Option<InputInitializer>,
flow_initializer: Option<InputInitializer>
) -> Self
pub fn new( array_order: i32, generic: bool, initializer: Option<InputInitializer>, flow_initializer: Option<InputInitializer> ) -> Self
Create a new Input
with an optional InputInitializer
sourcepub fn initializer(&self) -> &Option<InputInitializer>
pub fn initializer(&self) -> &Option<InputInitializer>
Return a reference to the initializer
sourcepub fn flow_initializer(&self) -> &Option<InputInitializer>
pub fn flow_initializer(&self) -> &Option<InputInitializer>
Return a reference to the flow initializer
sourcepub fn init(&mut self, first_time: bool, flow_idle: bool) -> bool
pub fn init(&mut self, first_time: bool, flow_idle: bool) -> bool
Initialize an input with the InputInitializer if it has one, either on the function directly or via a connection from a flow input When called at start-up it will initialize if it’s a OneTime or Always initializer When called after start-up it will initialize only if it’s a Always initializer
sourcepub fn take(&mut self) -> Value
pub fn take(&mut self) -> Value
Take the first element from the Input and return it. Could panic!
sourcepub fn values_available(&self) -> usize
pub fn values_available(&self) -> usize
Return the total number of values queued up in this input
Trait Implementations§
source§impl<'de> Deserialize<'de> for Input
impl<'de> Deserialize<'de> for Input
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>,
Deserialize this value from the given Serde deserializer. Read more
source§impl PartialEq for Input
impl PartialEq for Input
impl Eq for Input
impl StructuralEq for Input
impl StructuralPartialEq for Input
Auto Trait Implementations§
impl RefUnwindSafe for Input
impl Send for Input
impl Sync for Input
impl Unpin for Input
impl UnwindSafe for Input
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
§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.