pub struct RootVisitor<Value> {
    pub value: Value,
}

Fields§

§value: Value

Implementations§

source§

impl<'a, Value> RootVisitor<Value>

source

pub fn new(value: Value) -> Self

Trait Implementations§

source§

impl<Value: Clone> Clone for RootVisitor<Value>

source§

fn clone(&self) -> RootVisitor<Value>

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl<Value: Default> Default for RootVisitor<Value>

source§

fn default() -> RootVisitor<Value>

Returns the “default value” for a type. Read more
source§

impl<'a, Value> HasGet<'a> for &'a RootVisitor<Value>
where Value: Clone + Copy + KnowsPathSegment + HasGet<'a>, Value::GetType: KnowsPathSegment<PathSegment = Value::PathSegment> + KnowsParentVisitor<'a>, RootVisitor<Value>: Into<<Value::GetType as KnowsParentVisitor<'a>>::ParentVisitor>,

source§

fn get<K>(self, key: K) -> Option<Self::GetType>
where K: Into<<Self::GetType as KnowsPathSegment>::PathSegment>,

source§

impl<'a, Value> HasGet<'a> for RootVisitor<Value>
where Value: Copy + KnowsPathSegment + HasGet<'a>, Value::GetType: KnowsPathSegment<PathSegment = Value::PathSegment> + KnowsParentVisitor<'a>, Self: Into<<Value::GetType as KnowsParentVisitor<'a>>::ParentVisitor>,

source§

fn get<K>(self, key: K) -> Option<Self::GetType>
where K: Into<<Self::GetType as KnowsPathSegment>::PathSegment>,

source§

impl<'a, Value> HasParent<'a> for &'a RootVisitor<Value>
where Value: Clone,

source§

fn parent(self) -> Self::Parent

source§

impl<Value> HasPath<<Value as KnowsPathSegment>::PathSegment> for RootVisitor<Value>
where Value: HasPathSegment,

source§

fn path(&self) -> Path<Value::PathSegment>

source§

impl<'a, Value> HasPathSegment for &'a RootVisitor<Value>
where Value: HasPathSegment,

source§

fn path_segment(&self) -> &Self::PathSegment

source§

fn is(&self, identifier: impl PartialEq<Self::PathSegment>) -> bool

source§

impl<'a, Value> HasPathSegment for RootVisitor<Value>
where Value: HasPathSegment,

source§

fn path_segment(&self) -> &Self::PathSegment

source§

fn is(&self, identifier: impl PartialEq<Self::PathSegment>) -> bool

source§

impl<'a, Value> HasRelativeAccess<'a> for &'a RootVisitor<Value>
where Value: Copy + KnowsPathSegment + HasGet<'a> + KnowsRelativeAccessType<'a> + Clone + 'a, Value::GetType: KnowsPathSegment<PathSegment = Value::PathSegment> + KnowsParentVisitor<'a>, Self: Into<<Value::GetType as KnowsParentVisitor<'a>>::ParentVisitor> + Into<Self::RelativeType> + HasRoot<'a> + HasGet<'a>, <Self as KnowsGetType<'a>>::GetType: KnowsParentVisitor<'a> + Into<Self::RelativeType> + KnowsPathSegment<PathSegment = <Self as KnowsPathSegment>::PathSegment>, RootVisitor<Value>: Into<<<Self as KnowsGetType<'a>>::GetType as KnowsParentVisitor<'a>>::ParentVisitor>, &'a Self::RelativeType: HasRelativeAccess<'a, RelativeType = <Self as KnowsRelativeAccessType<'a>>::RelativeType, PathSegment = <Self as KnowsPathSegment>::PathSegment> + HasParent<'a> + HasRoot<'a>,

source§

fn relative<K>( self, path: impl IntoIterator<Item = K> ) -> Option<Self::RelativeType>
where K: Into<<Self as KnowsPathSegment>::PathSegment>,

source§

impl<'a, Value> HasRoot<'a> for &'a RootVisitor<Value>
where Value: Clone,

source§

fn root(self) -> Self::Root

source§

impl<'a, Value> IsVisitor<'a, Value> for RootVisitor<Value>
where Value: KnowsPathSegment,

source§

fn visit<Child>(self, value: Child) -> Visitor<Child::ParentVisitor, Child>
where Child: KnowsPathSegment<PathSegment = Value::PathSegment> + KnowsParentVisitor<'a>, Self: Into<Child::ParentVisitor>,

source§

impl<'a, Value> KnowsGetType<'a> for &'a RootVisitor<Value>
where Value: KnowsPathSegment + KnowsGetType<'a>, Value::GetType: KnowsPathSegment<PathSegment = Value::PathSegment> + KnowsParentVisitor<'a>,

§

type GetType = Visitor<<<Value as KnowsGetType<'a>>::GetType as KnowsParentVisitor<'a>>::ParentVisitor, <Value as KnowsGetType<'a>>::GetType>

source§

impl<'a, Value> KnowsGetType<'a> for RootVisitor<Value>
where Value: KnowsPathSegment + KnowsGetType<'a>, Value::GetType: KnowsPathSegment<PathSegment = Value::PathSegment> + KnowsParentVisitor<'a>,

§

type GetType = Visitor<<<Value as KnowsGetType<'a>>::GetType as KnowsParentVisitor<'a>>::ParentVisitor, <Value as KnowsGetType<'a>>::GetType>

source§

impl<'a, Value> KnowsParent<'a> for &'a RootVisitor<Value>

§

type Parent = RootVisitor<Value>

source§

impl<'a, Value> KnowsParentVisitor<'a> for RootVisitor<Value>

source§

impl<'a, Value> KnowsPathSegment for &'a RootVisitor<Value>
where Value: KnowsPathSegment,

source§

impl<'a, Value> KnowsPathSegment for RootVisitor<Value>
where Value: KnowsPathSegment,

source§

impl<'a, Value> KnowsRelativeAccessType<'a> for &'a RootVisitor<Value>
where Value: KnowsRelativeAccessType<'a>,

source§

impl<'a, Value> KnowsRoot<'a> for &'a RootVisitor<Value>

§

type Root = RootVisitor<Value>

source§

impl<Value: Copy> Copy for RootVisitor<Value>

Auto Trait Implementations§

§

impl<Value> RefUnwindSafe for RootVisitor<Value>
where Value: RefUnwindSafe,

§

impl<Value> Send for RootVisitor<Value>
where Value: Send,

§

impl<Value> Sync for RootVisitor<Value>
where Value: Sync,

§

impl<Value> Unpin for RootVisitor<Value>
where Value: Unpin,

§

impl<Value> UnwindSafe for RootVisitor<Value>
where Value: UnwindSafe,

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> IterType for T

source§

fn iter_type<T>(&self) -> TypeIterator<'_, T>
where Self: TypeIter<T>,

source§

impl<T> IterTypeMut for T

source§

fn iter_type_mut<T>(&mut self) -> TypeIterMut<'_, T>
where Self: IntoIterTypeMut<T>,

source§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.