Enum sppparse::SparseSelector [−][src]
pub enum SparseSelector<T> { Ref(SparseRefRaw<T>), Obj(SparsePointedValue<T>), Null, }
An owned selector between a raw object, a raw pointer or an owned pointer
Use this enum in your structure when allowing either a pointer or the value directly.
The SparseSelector allows to switch between a raw, unparsed pointer to a parsed pointer resolved at initialization.
Variants
Ref(SparseRefRaw<T>)
A deserialized JSON pointer contained the pointed value from the local or distant file
Obj(SparsePointedValue<T>)
The object included in the original document
A default value that should not be present once the SparseRoot document has been initialized.
Trait Implementations
impl<T: Clone> Clone for SparseSelector<T>
[src]
impl<T: Clone> Clone for SparseSelector<T>
[src]fn clone(&self) -> SparseSelector<T>
[src]
pub fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl<T> Default for SparseSelector<T> where
T: Any + DeserializeOwned + Serialize + SparsableTrait,
[src]
impl<T> Default for SparseSelector<T> where
T: Any + DeserializeOwned + Serialize + SparsableTrait,
[src]impl<'de, T> Deserialize<'de> for SparseSelector<T> where
T: Deserialize<'de>,
[src]
impl<'de, T> Deserialize<'de> for SparseSelector<T> where
T: Deserialize<'de>,
[src]fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
[src]
__D: Deserializer<'de>,
impl<T: PartialEq> PartialEq<SparseSelector<T>> for SparseSelector<T>
[src]
impl<T: PartialEq> PartialEq<SparseSelector<T>> for SparseSelector<T>
[src]fn eq(&self, other: &SparseSelector<T>) -> bool
[src]
fn ne(&self, other: &SparseSelector<T>) -> bool
[src]
impl<T> Serialize for SparseSelector<T> where
T: Serialize,
[src]
impl<T> Serialize for SparseSelector<T> where
T: Serialize,
[src]impl<T> Sparsable for SparseSelector<T> where
T: Any + DeserializeOwned + Serialize + SparsableTrait,
[src]
impl<T> Sparsable for SparseSelector<T> where
T: Any + DeserializeOwned + Serialize + SparsableTrait,
[src]fn sparse_init<'a>(
&mut self,
state: &mut SparseState,
metadata: &SparseMetadata,
depth: u32
) -> Result<(), SparseError>
[src]
&mut self,
state: &mut SparseState,
metadata: &SparseMetadata,
depth: u32
) -> Result<(), SparseError>
fn sparse_updt<'a>(
&mut self,
state: &mut SparseState,
metadata: &SparseMetadata,
depth: u32
) -> Result<(), SparseError>
[src]
&mut self,
state: &mut SparseState,
metadata: &SparseMetadata,
depth: u32
) -> Result<(), SparseError>
fn check_depth(&self, depth: u32) -> Result<(), SparseError>
[src]
impl<T> SparsePointer<T> for SparseSelector<T> where
T: Any + DeserializeOwned + Serialize + SparsableTrait,
[src]
impl<T> SparsePointer<T> for SparseSelector<T> where
T: Any + DeserializeOwned + Serialize + SparsableTrait,
[src]fn check_version<'a>(
&'a self,
state: &'a SparseState
) -> Result<(), SparseError>
[src]
&'a self,
state: &'a SparseState
) -> Result<(), SparseError>
fn get(&self) -> Result<SparseValue<'_, T>, SparseError>
[src]
fn get_mut(
&mut self,
root: Rc<RefCell<SparseState>>
) -> Result<SparseValueMut<'_, T>, SparseError>
[src]
&mut self,
root: Rc<RefCell<SparseState>>
) -> Result<SparseValueMut<'_, T>, SparseError>
fn self_reset(
&mut self,
state: &mut SparseState,
metadata: &SparseMetadata,
depth: u32
) -> Result<(), SparseError>
[src]
&mut self,
state: &mut SparseState,
metadata: &SparseMetadata,
depth: u32
) -> Result<(), SparseError>
impl<T> StructuralPartialEq for SparseSelector<T>
[src]
impl<T> StructuralPartialEq for SparseSelector<T>
[src]Auto Trait Implementations
impl<T> RefUnwindSafe for SparseSelector<T> where
T: RefUnwindSafe,
impl<T> RefUnwindSafe for SparseSelector<T> where
T: RefUnwindSafe,
impl<T> Send for SparseSelector<T> where
T: Send,
impl<T> Send for SparseSelector<T> where
T: Send,
impl<T> Sync for SparseSelector<T> where
T: Sync,
impl<T> Sync for SparseSelector<T> where
T: Sync,
impl<T> Unpin for SparseSelector<T> where
T: Unpin,
impl<T> Unpin for SparseSelector<T> where
T: Unpin,
impl<T> UnwindSafe for SparseSelector<T> where
T: UnwindSafe,
impl<T> UnwindSafe for SparseSelector<T> where
T: UnwindSafe,