pub struct AnyMergeVarBuilder { /* private fields */ }Expand description
Build a merge_var! from any number of input vars of any type.
Implementations§
Source§impl AnyMergeVarBuilder
impl AnyMergeVarBuilder
Sourcepub fn with_capacity(capacity: usize) -> Self
pub fn with_capacity(capacity: usize) -> Self
New with pre-allocated inputs.
Sourcepub fn build_any(
self,
merge: impl FnMut(&[AnyVar]) -> BoxAnyVarValue + Send + 'static,
output_type: TypeId,
) -> AnyVar
pub fn build_any( self, merge: impl FnMut(&[AnyVar]) -> BoxAnyVarValue + Send + 'static, output_type: TypeId, ) -> AnyVar
Build a read-only merge var.
Sourcepub fn build<O: VarValue>(
self,
merge: impl FnMut(&[AnyVar]) -> O + Send + 'static,
) -> Var<O>
pub fn build<O: VarValue>( self, merge: impl FnMut(&[AnyVar]) -> O + Send + 'static, ) -> Var<O>
Build a read-only strongly typed merge var.
Sourcepub fn build_bidi_any(
self,
merge: impl FnMut(&[AnyVar]) -> BoxAnyVarValue + Send + 'static,
map_back: impl FnMut(&dyn AnyVarValue, usize) -> BoxAnyVarValue + Send + 'static,
output_type: TypeId,
) -> AnyVar
pub fn build_bidi_any( self, merge: impl FnMut(&[AnyVar]) -> BoxAnyVarValue + Send + 'static, map_back: impl FnMut(&dyn AnyVarValue, usize) -> BoxAnyVarValue + Send + 'static, output_type: TypeId, ) -> AnyVar
Build a read-write merge var.
Sourcepub fn build_bidi_any_modify(
self,
merge: impl FnMut(&[AnyVar]) -> BoxAnyVarValue + Send + 'static,
modify_back: impl FnMut(&dyn AnyVarValue, usize, &mut AnyVarModify<'_>) + Send + 'static,
output_type: TypeId,
) -> AnyVar
pub fn build_bidi_any_modify( self, merge: impl FnMut(&[AnyVar]) -> BoxAnyVarValue + Send + 'static, modify_back: impl FnMut(&dyn AnyVarValue, usize, &mut AnyVarModify<'_>) + Send + 'static, output_type: TypeId, ) -> AnyVar
Build a read-write merge var that modifies each input back.
Sourcepub fn build_bidi<O: VarValue>(
self,
merge: impl FnMut(&[AnyVar]) -> O + Send + 'static,
map_back: impl FnMut(&O, usize) -> BoxAnyVarValue + Send + 'static,
) -> Var<O>
pub fn build_bidi<O: VarValue>( self, merge: impl FnMut(&[AnyVar]) -> O + Send + 'static, map_back: impl FnMut(&O, usize) -> BoxAnyVarValue + Send + 'static, ) -> Var<O>
Build a read-write strongly typed merge var.
Sourcepub fn build_bidi_modify<O: VarValue>(
self,
merge: impl FnMut(&[AnyVar]) -> O + Send + 'static,
modify_back: impl FnMut(&O, usize, &mut AnyVarModify<'_>) + Send + 'static,
) -> Var<O>
pub fn build_bidi_modify<O: VarValue>( self, merge: impl FnMut(&[AnyVar]) -> O + Send + 'static, modify_back: impl FnMut(&O, usize, &mut AnyVarModify<'_>) + Send + 'static, ) -> Var<O>
Build a read-write strongly typed merge var that modifies each input back.
Sourcepub fn into_typed<I: VarValue>(self) -> MergeVarBuilder<I>
pub fn into_typed<I: VarValue>(self) -> MergeVarBuilder<I>
Trait Implementations§
Source§impl Clone for AnyMergeVarBuilder
impl Clone for AnyMergeVarBuilder
Source§fn clone(&self) -> AnyMergeVarBuilder
fn clone(&self) -> AnyMergeVarBuilder
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for AnyMergeVarBuilder
impl !RefUnwindSafe for AnyMergeVarBuilder
impl Send for AnyMergeVarBuilder
impl Sync for AnyMergeVarBuilder
impl !Unpin for AnyMergeVarBuilder
impl UnsafeUnpin for AnyMergeVarBuilder
impl !UnwindSafe for AnyMergeVarBuilder
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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>
Converts
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>
Converts
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