pub struct NestedFieldPathSet<F, S, U> { /* private fields */ }
Expand description
Allows accessing multiple fields inside of some nested field.
This is most useful for accessing multiple fields inside of a (nested) enum.
This is the type that fp!(a.b => b, c, d)
and fp!(::Foo => bar, baz, qux)
construct.
§Uniqueness
If the U
type parameter is a:
-
UniquePaths
: all the field paths are unique, and this can be passed toStructuralExt::fields_mut
andStructuralExt::into_fields
. -
AliasedPaths
: there might be repeated field paths. This cannot be passed toStructuralExt::fields_mut
, because it might borrow the same field mutably twice. This can also not be passed toStructuralExt::into_fields
, because a field cannot generally be moved out twice.
§Construction
NestedFieldPathSet can be constructed in these ways:
-
Using the
fp
macro.
Example:fp!(::Foo=>a,b)
, this gets thea
,andb
fields from inside theFoo
variant.
Example:fp!(a.b=>uh,what)
, this gets theuh
,andwhat
fields from inside thea.b
field. -
Constructing it from a
NestedFieldPath
and aFieldPathSet
.
Example:NestedFieldPathSet::new( fp!(a.b.c), fp!(foo,bar,baz) )
, this gets thefoo
,bar
,andbaz
fields from inside thea.b.c
field.
Example:NestedFieldPathSet::new( fp!(::Foo), fp!(a,b) )
, this gets thea
,andb
fields from inside theFoo
variant. -
Using the
NEW
associated constant, ifF
andS
implementscore_extensions::ConstDefault
(reexported instructural::reexports::ConstDefault
) Example:<FP!(::Foo=>a,b,c)>::NEW
§Drop Types
To make all the inherent methods in this type const fn
this type wraps the NestedFieldPath<F>
inside a ManuallyDrop
,
which means that F
won’t be dropped inside.
If that is a problem don’t construct a NestedFieldPathSet with an F
that owns some resource.
§Examples
You can look for examples of using this in the multi-field
StructuralExt
methods, like fields
,fields_mut
,and into_fields
(look for the enum examples).
Implementations§
Source§impl<F, S> NestedFieldPathSet<F, S, AliasedPaths>where
F: ConstDefault,
S: ConstDefault,
impl<F, S> NestedFieldPathSet<F, S, AliasedPaths>where
F: ConstDefault,
S: ConstDefault,
Source§impl<F, S, U> NestedFieldPathSet<F, S, U>where
F: ConstDefault,
S: ConstDefault,
impl<F, S, U> NestedFieldPathSet<F, S, U>where
F: ConstDefault,
S: ConstDefault,
Sourcepub const NEW_ALIASED: NestedFieldPathSet<F, S, AliasedPaths> = NestedFieldPathSet::NEW
pub const NEW_ALIASED: NestedFieldPathSet<F, S, AliasedPaths> = NestedFieldPathSet::NEW
This can be used to construct a NestedFieldPathSet<T, UniquePaths>
from a type alias,
by doing unsafe{ FOO::NEW_ALIASED.upgrade_unchecked() }
(read the docs for upgrade_unchecked
first).
Source§impl<F, S, U> NestedFieldPathSet<F, S, U>
impl<F, S, U> NestedFieldPathSet<F, S, U>
Sourcepub const fn new(nested: F, set: FieldPathSet<S, U>) -> Self
pub const fn new(nested: F, set: FieldPathSet<S, U>) -> Self
Constructs a NestedFieldPathSet
from an F
and a FieldPathSet
Sourcepub const fn into_inner(self) -> (F, FieldPathSet<S, U>)
pub const fn into_inner(self) -> (F, FieldPathSet<S, U>)
Unwraps a NestedFieldPathSet
into a NestedFieldPath
and a FieldPathSet
Sourcepub const fn into_nested(self) -> F
pub const fn into_nested(self) -> F
Unwraps a NestedFieldPathSet
into the NestedFieldPath
for the nested field.
Sourcepub const fn into_set(self) -> FieldPathSet<S, U>
pub const fn into_set(self) -> FieldPathSet<S, U>
Unwraps a NestedFieldPathSet
into the FieldPathSet
used to
access the multiple fields inside a nested field.
Source§impl<F, S> NestedFieldPathSet<F, S, UniquePaths>
impl<F, S> NestedFieldPathSet<F, S, UniquePaths>
Sourcepub const fn downgrade(self) -> NestedFieldPathSet<F, S, AliasedPaths>
pub const fn downgrade(self) -> NestedFieldPathSet<F, S, AliasedPaths>
Converts a NestedFieldPathSet<F, S, UniquePaths>
to a
NestedFieldPathSet<F, S, AliasedPaths>
Source§impl<F, S> NestedFieldPathSet<F, S, AliasedPaths>
impl<F, S> NestedFieldPathSet<F, S, AliasedPaths>
Sourcepub const unsafe fn upgrade_unchecked(
self,
) -> NestedFieldPathSet<F, S, UniquePaths>
pub const unsafe fn upgrade_unchecked( self, ) -> NestedFieldPathSet<F, S, UniquePaths>
Converts a NestedFieldPathSet<F, S, AliasedPaths>
to a
NestedFieldPathSet<F, S, UniquePaths>
§Safety
You must ensure that all the field paths in in the S
type parameter are unique,
there must be no field path that is a prefix of any other field path.
Sourcepub const unsafe fn set_uniqueness<U>(self) -> NestedFieldPathSet<F, S, U>
pub const unsafe fn set_uniqueness<U>(self) -> NestedFieldPathSet<F, S, U>
Converts a NestedFieldPathSet<F, S, AliasedPaths>
to a
NestedFieldPathSet<F, S, U>
§Safety
If U == UniquePaths
,
you must ensure that all the field paths in the S
type parameter are unique,
there must be no field path that is a prefix of any other field path.
Trait Implementations§
Source§impl<F: Clone, S: Clone, U: Clone> Clone for NestedFieldPathSet<F, S, U>
impl<F: Clone, S: Clone, U: Clone> Clone for NestedFieldPathSet<F, S, U>
Source§fn clone(&self) -> NestedFieldPathSet<F, S, U>
fn clone(&self) -> NestedFieldPathSet<F, S, U>
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl<F, S> ConstDefault for NestedFieldPathSet<F, S, AliasedPaths>where
F: ConstDefault,
S: ConstDefault,
impl<F, S> ConstDefault for NestedFieldPathSet<F, S, AliasedPaths>where
F: ConstDefault,
S: ConstDefault,
Source§impl<F, S> Default for NestedFieldPathSet<F, S, AliasedPaths>
impl<F, S> Default for NestedFieldPathSet<F, S, AliasedPaths>
Source§impl<F, S, U> IntoAliasing for NestedFieldPathSet<F, S, U>
impl<F, S, U> IntoAliasing for NestedFieldPathSet<F, S, U>
Source§type Output = NestedFieldPathSet<F, S, AliasedPaths>
type Output = NestedFieldPathSet<F, S, AliasedPaths>
Source§impl<F, S, U> IsMultiFieldPath for NestedFieldPathSet<F, S, U>
impl<F, S, U> IsMultiFieldPath for NestedFieldPathSet<F, S, U>
Source§type PathUniqueness = U
type PathUniqueness = U
Source§impl<This, A, B, U> RevFieldErr<This> for NestedFieldPathSet<A, (B,), U>
impl<This, A, B, U> RevFieldErr<This> for NestedFieldPathSet<A, (B,), U>
Source§type Err = <(<A as RevFieldErr<This>>::Err, <B as RevFieldErr<<A as RevFieldType<This>>::Ty>>::Err) as CombinedErrs>::Combined
type Err = <(<A as RevFieldErr<This>>::Err, <B as RevFieldErr<<A as RevFieldType<This>>::Ty>>::Err) as CombinedErrs>::Combined
rev_*
methods. Read moreSource§impl<This, A, B, U> RevFieldType<This> for NestedFieldPathSet<A, (B,), U>
impl<This, A, B, U> RevFieldType<This> for NestedFieldPathSet<A, (B,), U>
Source§type Ty = <B as RevFieldType<<A as RevFieldType<This>>::Ty>>::Ty
type Ty = <B as RevFieldType<<A as RevFieldType<This>>::Ty>>::Ty
Source§impl<'a, This, A, B, U> RevGetFieldImpl<'a, This> for NestedFieldPathSet<A, (B,), U>where
This: ?Sized + 'a,
A: RevGetFieldImpl<'a, This>,
B: RevGetFieldImpl<'a, A::Ty>,
A::Ty: 'a,
Self: RevFieldErr<This, Ty = B::Ty>,
A::Err: IntoFieldErr<Self::Err>,
B::Err: IntoFieldErr<Self::Err>,
impl<'a, This, A, B, U> RevGetFieldImpl<'a, This> for NestedFieldPathSet<A, (B,), U>where
This: ?Sized + 'a,
A: RevGetFieldImpl<'a, This>,
B: RevGetFieldImpl<'a, A::Ty>,
A::Ty: 'a,
Self: RevFieldErr<This, Ty = B::Ty>,
A::Err: IntoFieldErr<Self::Err>,
B::Err: IntoFieldErr<Self::Err>,
Source§impl<'a, This, A, B, U> RevGetFieldMutImpl<'a, This> for NestedFieldPathSet<A, (B,), U>where
This: ?Sized + 'a,
A: RevGetFieldMutImpl<'a, This>,
B: RevGetFieldMutImpl<'a, A::Ty>,
A::Ty: 'a,
Self: RevFieldErr<This, Ty = B::Ty>,
A::Err: IntoFieldErr<Self::Err>,
B::Err: IntoFieldErr<Self::Err>,
impl<'a, This, A, B, U> RevGetFieldMutImpl<'a, This> for NestedFieldPathSet<A, (B,), U>where
This: ?Sized + 'a,
A: RevGetFieldMutImpl<'a, This>,
B: RevGetFieldMutImpl<'a, A::Ty>,
A::Ty: 'a,
Self: RevFieldErr<This, Ty = B::Ty>,
A::Err: IntoFieldErr<Self::Err>,
B::Err: IntoFieldErr<Self::Err>,
Source§fn rev_get_field_mut(
self,
this: &'a mut This,
) -> Result<&'a mut B::Ty, Self::Err>
fn rev_get_field_mut( self, this: &'a mut This, ) -> Result<&'a mut B::Ty, Self::Err>
self
represents inside of this
,by mutable reference.Source§impl<'a, F, S, U, This, Mid, OutTy, OutErr> RevGetMultiFieldImpl<'a, This> for NestedFieldPathSet<F, S, U>where
F: RevGetFieldImpl<'a, This, Ty = Mid, Err = OutErr>,
FieldPathSet<S, U>: RevGetMultiFieldImpl<'a, Mid, UnnormFields = OutTy>,
OutErr: IsFieldErr,
This: 'a + ?Sized,
Mid: 'a + ?Sized,
OutTy: 'a + NormalizeFields,
NestedFieldPathSetOutput<OutTy, OutErr>: 'a + NormalizeFields,
impl<'a, F, S, U, This, Mid, OutTy, OutErr> RevGetMultiFieldImpl<'a, This> for NestedFieldPathSet<F, S, U>where
F: RevGetFieldImpl<'a, This, Ty = Mid, Err = OutErr>,
FieldPathSet<S, U>: RevGetMultiFieldImpl<'a, Mid, UnnormFields = OutTy>,
OutErr: IsFieldErr,
This: 'a + ?Sized,
Mid: 'a + ?Sized,
OutTy: 'a + NormalizeFields,
NestedFieldPathSetOutput<OutTy, OutErr>: 'a + NormalizeFields,
Source§type UnnormFields = NestedFieldPathSetOutput<OutTy, OutErr>
type UnnormFields = NestedFieldPathSetOutput<OutTy, OutErr>
Results<&'a _,_>
s referencing fields.Source§fn rev_get_multi_field_impl(
self,
this: &'a This,
) -> NestedFieldPathSetOutput<OutTy, OutErr>
fn rev_get_multi_field_impl( self, this: &'a This, ) -> NestedFieldPathSetOutput<OutTy, OutErr>
this
.Source§impl<'a, F, S, This, Mid, OutTy, OutRawTy, OutErr> RevGetMultiFieldMutImpl<'a, This> for NestedFieldPathSet<F, S, UniquePaths>where
F: RevGetFieldMutImpl<'a, This, Ty = Mid, Err = OutErr>,
FieldPathSet<S, UniquePaths>: RevGetMultiFieldMutImpl<'a, Mid, UnnormFieldsMut = OutTy, UnnormFieldsRawMut = OutRawTy>,
This: 'a + ?Sized,
OutErr: IsFieldErr,
Mid: 'a + ?Sized,
OutTy: 'a + NormalizeFields,
OutRawTy: 'a + NormalizeFields,
NestedFieldPathSetOutput<OutTy, OutErr>: 'a + NormalizeFields,
NestedFieldPathSetOutput<OutRawTy, OutErr>: 'a + NormalizeFields,
impl<'a, F, S, This, Mid, OutTy, OutRawTy, OutErr> RevGetMultiFieldMutImpl<'a, This> for NestedFieldPathSet<F, S, UniquePaths>where
F: RevGetFieldMutImpl<'a, This, Ty = Mid, Err = OutErr>,
FieldPathSet<S, UniquePaths>: RevGetMultiFieldMutImpl<'a, Mid, UnnormFieldsMut = OutTy, UnnormFieldsRawMut = OutRawTy>,
This: 'a + ?Sized,
OutErr: IsFieldErr,
Mid: 'a + ?Sized,
OutTy: 'a + NormalizeFields,
OutRawTy: 'a + NormalizeFields,
NestedFieldPathSetOutput<OutTy, OutErr>: 'a + NormalizeFields,
NestedFieldPathSetOutput<OutRawTy, OutErr>: 'a + NormalizeFields,
Source§type UnnormFieldsMut = NestedFieldPathSetOutput<OutTy, OutErr>
type UnnormFieldsMut = NestedFieldPathSetOutput<OutTy, OutErr>
Result<&mut _,E: IsFieldErr>
s.Source§type UnnormFieldsRawMut = NestedFieldPathSetOutput<OutRawTy, OutErr>
type UnnormFieldsRawMut = NestedFieldPathSetOutput<OutRawTy, OutErr>
Result<*mut _,E: IsFieldErr>
s.Source§fn rev_get_multi_field_mut_impl(
self,
this: &'a mut This,
) -> NestedFieldPathSetOutput<OutTy, OutErr>
fn rev_get_multi_field_mut_impl( self, this: &'a mut This, ) -> NestedFieldPathSetOutput<OutTy, OutErr>
this
,
usually a tuple of Result<&mut _,E: IsFieldErr>
s.Source§unsafe fn rev_get_multi_field_raw_mut_impl(
self,
this: *mut This,
) -> NestedFieldPathSetOutput<OutRawTy, OutErr>
unsafe fn rev_get_multi_field_raw_mut_impl( self, this: *mut This, ) -> NestedFieldPathSetOutput<OutRawTy, OutErr>
this
,
usually a tuple of Result<*mut _,E: IsFieldErr>
s. Read moreSource§impl<This, A, B, U> RevIntoFieldImpl<This> for NestedFieldPathSet<A, (B,), U>where
This: ?Sized,
A: RevIntoFieldImpl<This>,
B: RevIntoFieldImpl<A::Ty>,
A::Ty: Sized,
Self: RevFieldErr<This, Ty = B::Ty>,
A::Err: IntoFieldErr<Self::Err>,
B::Err: IntoFieldErr<Self::Err>,
impl<This, A, B, U> RevIntoFieldImpl<This> for NestedFieldPathSet<A, (B,), U>where
This: ?Sized,
A: RevIntoFieldImpl<This>,
B: RevIntoFieldImpl<A::Ty>,
A::Ty: Sized,
Self: RevFieldErr<This, Ty = B::Ty>,
A::Err: IntoFieldErr<Self::Err>,
B::Err: IntoFieldErr<Self::Err>,
Source§impl<F, S, This, Mid, OutTy, OutErr> RevIntoMultiFieldImpl<This> for NestedFieldPathSet<F, S, UniquePaths>where
F: RevIntoFieldImpl<This, Ty = Mid, Err = OutErr>,
FieldPathSet<S, UniquePaths>: RevIntoMultiFieldImpl<Mid, UnnormIntoFields = OutTy>,
OutTy: NormalizeFields,
OutErr: IsFieldErr,
NestedFieldPathSetOutput<OutTy, OutErr>: NormalizeFields,
impl<F, S, This, Mid, OutTy, OutErr> RevIntoMultiFieldImpl<This> for NestedFieldPathSet<F, S, UniquePaths>where
F: RevIntoFieldImpl<This, Ty = Mid, Err = OutErr>,
FieldPathSet<S, UniquePaths>: RevIntoMultiFieldImpl<Mid, UnnormIntoFields = OutTy>,
OutTy: NormalizeFields,
OutErr: IsFieldErr,
NestedFieldPathSetOutput<OutTy, OutErr>: NormalizeFields,
Source§type UnnormIntoFields = NestedFieldPathSetOutput<OutTy, OutErr>
type UnnormIntoFields = NestedFieldPathSetOutput<OutTy, OutErr>
Result<_, E: IsFieldErr>
s.Source§fn rev_into_multi_field_impl(self, this: This) -> Self::UnnormIntoFields
fn rev_into_multi_field_impl(self, this: This) -> Self::UnnormIntoFields
this
into multiple fields by value,
usually a tuple of Result<_, E: IsFieldErr>
s.impl<F: Copy, S: Copy, U: Copy> Copy for NestedFieldPathSet<F, S, U>
impl<F, S, U> IsSingleFieldPath for NestedFieldPathSet<F, (S,), U>
Auto Trait Implementations§
impl<F, S, U> Freeze for NestedFieldPathSet<F, S, U>
impl<F, S, U> RefUnwindSafe for NestedFieldPathSet<F, S, U>
impl<F, S, U> Send for NestedFieldPathSet<F, S, U>
impl<F, S, U> Sync for NestedFieldPathSet<F, S, U>
impl<F, S, U> Unpin for NestedFieldPathSet<F, S, U>
impl<F, S, U> UnwindSafe for NestedFieldPathSet<F, S, U>
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<This> EnumExt for Thiswhere
This: ?Sized,
impl<This> EnumExt for Thiswhere
This: ?Sized,
Source§fn as_variant<V>(
&self,
vari: TStr<V>,
) -> Result<&VariantProxy<Self, TStr<V>>, &Self>
fn as_variant<V>( &self, vari: TStr<V>, ) -> Result<&VariantProxy<Self, TStr<V>>, &Self>
Source§fn as_mut_variant<V>(
&mut self,
vari: TStr<V>,
) -> Result<&mut VariantProxy<Self, TStr<V>>, &mut Self>
fn as_mut_variant<V>( &mut self, vari: TStr<V>, ) -> Result<&mut VariantProxy<Self, TStr<V>>, &mut Self>
Source§impl<This, T> IntoStructural<T> for Thiswhere
T: FromStructural<This>,
impl<This, T> IntoStructural<T> for Thiswhere
T: FromStructural<This>,
Source§fn into_structural(self) -> T
fn into_structural(self) -> T
Source§impl<'a, This, Path> RevGetMultiField<'a, This> for Pathwhere
This: 'a + ?Sized,
Path: RevGetMultiFieldImpl<'a, This>,
impl<'a, This, Path> RevGetMultiField<'a, This> for Pathwhere
This: 'a + ?Sized,
Path: RevGetMultiFieldImpl<'a, This>,
Source§type Fields = <<Path as RevGetMultiFieldImpl<'a, This>>::UnnormFields as NormalizeFields>::Output
type Fields = <<Path as RevGetMultiFieldImpl<'a, This>>::UnnormFields as NormalizeFields>::Output
Option<&_>
s and &_
s.Source§fn rev_get_multi_field(
self,
this: &'a This,
) -> <Path as RevGetMultiField<'a, This>>::Fields
fn rev_get_multi_field( self, this: &'a This, ) -> <Path as RevGetMultiField<'a, This>>::Fields
this
,
usually a tuple of Option<&_>
s and &_
s.Source§impl<'a, This, Path> RevGetMultiFieldMut<'a, This> for Pathwhere
This: 'a + ?Sized,
Path: RevGetMultiFieldMutImpl<'a, This>,
impl<'a, This, Path> RevGetMultiFieldMut<'a, This> for Pathwhere
This: 'a + ?Sized,
Path: RevGetMultiFieldMutImpl<'a, This>,
Source§type FieldsMut = <<Path as RevGetMultiFieldMutImpl<'a, This>>::UnnormFieldsMut as NormalizeFields>::Output
type FieldsMut = <<Path as RevGetMultiFieldMutImpl<'a, This>>::UnnormFieldsMut as NormalizeFields>::Output
Option<&mut _>
s and &mut _
s.Source§type FieldsRawMut = <<Path as RevGetMultiFieldMutImpl<'a, This>>::UnnormFieldsRawMut as NormalizeFields>::Output
type FieldsRawMut = <<Path as RevGetMultiFieldMutImpl<'a, This>>::UnnormFieldsRawMut as NormalizeFields>::Output
Option<*mut _>
s and *mut _
s.Source§fn rev_get_multi_field_mut(
self,
this: &'a mut This,
) -> <Path as RevGetMultiFieldMut<'a, This>>::FieldsMut
fn rev_get_multi_field_mut( self, this: &'a mut This, ) -> <Path as RevGetMultiFieldMut<'a, This>>::FieldsMut
this
,
usually a tuple of Option<&mut _>
s and &mut _
s.Source§unsafe fn rev_get_multi_field_raw_mut(
self,
this: *mut This,
) -> <Path as RevGetMultiFieldMut<'a, This>>::FieldsRawMut
unsafe fn rev_get_multi_field_raw_mut( self, this: *mut This, ) -> <Path as RevGetMultiFieldMut<'a, This>>::FieldsRawMut
this
,
usually a tuple of Option<*mut _>
s and *mut _
s. Read moreSource§impl<This, Path> RevIntoMultiField<This> for Pathwhere
Path: RevIntoMultiFieldImpl<This>,
impl<This, Path> RevIntoMultiField<This> for Pathwhere
Path: RevIntoMultiFieldImpl<This>,
Source§type IntoFields = <<Path as RevIntoMultiFieldImpl<This>>::UnnormIntoFields as NormalizeFields>::Output
type IntoFields = <<Path as RevIntoMultiFieldImpl<This>>::UnnormIntoFields as NormalizeFields>::Output
Option<T>
s and T
s.Source§fn rev_into_multi_field(
self,
this: This,
) -> <Path as RevIntoMultiField<This>>::IntoFields
fn rev_into_multi_field( self, this: This, ) -> <Path as RevIntoMultiField<This>>::IntoFields
this
into multiple fields by value.
usually a tuple of Option<T>
s and T
s.Source§impl<T> SelfOps for Twhere
T: ?Sized,
impl<T> SelfOps for Twhere
T: ?Sized,
Source§const T: PhantomData<fn() -> Self> = PhantomData
const T: PhantomData<fn() -> Self> = PhantomData
Type::T
to pass it in methods with _:VariantPhantom<T>
parameters. Read moreSource§const T_D: PhantomData<Self> = PhantomData
const T_D: PhantomData<Self> = PhantomData
Source§fn assert_ty(self, _other: PhantomData<fn() -> Self>) -> Selfwhere
Self: Sized,
fn assert_ty(self, _other: PhantomData<fn() -> Self>) -> Selfwhere
Self: Sized,
other
is the same type as self
.Source§fn assert_ty_ref(&self, _other: PhantomData<fn() -> Self>) -> &Selfwhere
Self: Sized,
fn assert_ty_ref(&self, _other: PhantomData<fn() -> Self>) -> &Selfwhere
Self: Sized,
other
is the same type as self
.Source§fn assert_ty_mut(&mut self, _other: PhantomData<fn() -> Self>) -> &mut Selfwhere
Self: Sized,
fn assert_ty_mut(&mut self, _other: PhantomData<fn() -> Self>) -> &mut Selfwhere
Self: Sized,
other
is the same type as self
.Source§fn ty_(&self) -> PhantomData<fn() -> Self>
fn ty_(&self) -> PhantomData<fn() -> Self>
Source§fn ty_inv(&self) -> PhantomData<fn(Self) -> Self>
fn ty_inv(&self) -> PhantomData<fn(Self) -> Self>
Source§fn ty_inv_ref(&self) -> PhantomData<Cell<&Self>>
fn ty_inv_ref(&self) -> PhantomData<Cell<&Self>>
Source§fn eq_id(&self, other: &Self) -> bool
fn eq_id(&self, other: &Self) -> bool
Source§fn piped<F, U>(self, f: F) -> U
fn piped<F, U>(self, f: F) -> U
Source§fn piped_ref<'a, F, U>(&'a self, f: F) -> Uwhere
F: FnOnce(&'a Self) -> U,
fn piped_ref<'a, F, U>(&'a self, f: F) -> Uwhere
F: FnOnce(&'a Self) -> U,
piped
except that the function takes &Self
Useful for functions that take &Self
instead of Self
. Read moreSource§fn piped_mut<'a, F, U>(&'a mut self, f: F) -> Uwhere
F: FnOnce(&'a mut Self) -> U,
fn piped_mut<'a, F, U>(&'a mut self, f: F) -> Uwhere
F: FnOnce(&'a mut Self) -> U,
piped
except that the function takes &mut Self
.
Useful for functions that take &mut Self
instead of Self
.Source§fn mutated<F>(self, f: F) -> Self
fn mutated<F>(self, f: F) -> Self
Source§fn observe<F>(self, f: F) -> Self
fn observe<F>(self, f: F) -> Self
Source§fn into_<T>(self, _: PhantomData<fn() -> T>) -> Twhere
Self: Into<T>,
fn into_<T>(self, _: PhantomData<fn() -> T>) -> Twhere
Self: Into<T>,
Source§fn as_ref_<T>(&self) -> &T
fn as_ref_<T>(&self) -> &T
.as_ref_::<_>()
syntax. Read moreSource§impl<T> StructuralExt for Twhere
T: ?Sized,
impl<T> StructuralExt for Twhere
T: ?Sized,
Source§fn field_<'a, P>(
&'a self,
path: P,
) -> NormalizeFieldsOut<Result<&'a P::Ty, P::Err>>
fn field_<'a, P>( &'a self, path: P, ) -> NormalizeFieldsOut<Result<&'a P::Ty, P::Err>>
path
. Read moreSource§fn fields<'a, P>(&'a self, path: P) -> RevGetMultiFieldOut<'a, P, Self>where
P: RevGetMultiField<'a, Self>,
fn fields<'a, P>(&'a self, path: P) -> RevGetMultiFieldOut<'a, P, Self>where
P: RevGetMultiField<'a, Self>,
path
. Read moreSource§fn cloned_fields<'a, P>(
&'a self,
path: P,
) -> ClonedOut<RevGetMultiFieldOut<'a, P, Self>>
fn cloned_fields<'a, P>( &'a self, path: P, ) -> ClonedOut<RevGetMultiFieldOut<'a, P, Self>>
path
. Read moreSource§fn field_mut<'a, P>(
&'a mut self,
path: P,
) -> NormalizeFieldsOut<Result<&'a mut P::Ty, P::Err>>
fn field_mut<'a, P>( &'a mut self, path: P, ) -> NormalizeFieldsOut<Result<&'a mut P::Ty, P::Err>>
path
. Read moreSource§fn fields_mut<'a, P>(
&'a mut self,
path: P,
) -> RevGetMultiFieldMutOut<'a, P, Self>where
P: RevGetMultiFieldMut<'a, Self>,
fn fields_mut<'a, P>(
&'a mut self,
path: P,
) -> RevGetMultiFieldMutOut<'a, P, Self>where
P: RevGetMultiFieldMut<'a, Self>,
path
. Read moreSource§fn into_field<P>(self, path: P) -> NormalizeFieldsOut<Result<P::Ty, P::Err>>
fn into_field<P>(self, path: P) -> NormalizeFieldsOut<Result<P::Ty, P::Err>>
path
. Read moreSource§fn into_fields<P>(self, path: P) -> RevIntoMultiFieldOut<P, Self>where
P: RevIntoMultiField<Self>,
Self: Sized,
fn into_fields<P>(self, path: P) -> RevIntoMultiFieldOut<P, Self>where
P: RevIntoMultiField<Self>,
Self: Sized,
self
into multiple fields by value. Read moreSource§fn is_variant<P>(&self, _path: P) -> bool
fn is_variant<P>(&self, _path: P) -> bool
Source§fn into_struc<U>(self) -> Uwhere
Self: IntoStructural<U>,
fn into_struc<U>(self) -> Uwhere
Self: IntoStructural<U>,
IntoStructural
. Read moreSource§fn try_into_struc<U>(self) -> Result<U, TryFromError<Self, Self::Error>>where
Self: TryIntoStructural<U>,
fn try_into_struc<U>(self) -> Result<U, TryFromError<Self, Self::Error>>where
Self: TryIntoStructural<U>,
TryIntoStructural
. Read moreSource§impl<This, T> TryIntoStructural<T> for Thiswhere
T: TryFromStructural<This>,
impl<This, T> TryIntoStructural<T> for Thiswhere
T: TryFromStructural<This>,
Source§type Error = <T as TryFromStructural<This>>::Error
type Error = <T as TryFromStructural<This>>::Error
TryFromError
,
returned from try_into_structural
on conversion error.