pub trait JsonPointee: Any {
// Required method
fn resolve(
&self,
pointer: JsonPointer<'_>,
) -> Result<&dyn JsonPointee, BadJsonPointer>;
}Expand description
A value that a JsonPointer points to.
Required Methods§
Sourcefn resolve(
&self,
pointer: JsonPointer<'_>,
) -> Result<&dyn JsonPointee, BadJsonPointer>
fn resolve( &self, pointer: JsonPointer<'_>, ) -> Result<&dyn JsonPointee, BadJsonPointer>
Resolves a JsonPointer against this value.
Implementations§
Source§impl dyn JsonPointee
impl dyn JsonPointee
Sourcepub fn downcast_ref<T: JsonPointee>(&self) -> Option<&T>
pub fn downcast_ref<T: JsonPointee>(&self) -> Option<&T>
Returns a reference to the pointed-to value if it’s of type T,
or None if it isn’t.
Sourcepub fn is<T: JsonPointee>(&self) -> bool
pub fn is<T: JsonPointee>(&self) -> bool
Returns true if the pointed-to value is of type T.