pub struct JsonPointerBuf(/* private fields */);Expand description
JSON Pointer buffer.
Implementations§
Source§impl JsonPointerBuf
impl JsonPointerBuf
Sourcepub fn new<B>(value: B) -> Result<JsonPointerBuf, InvalidJsonPointer<B>>where
B: BytesBuf,
pub fn new<B>(value: B) -> Result<JsonPointerBuf, InvalidJsonPointer<B>>where
B: BytesBuf,
Converts the given byte string into an owned JSON pointer.
pub fn push(&mut self, token: &str)
pub fn push_index(&mut self, i: usize)
pub fn as_json_pointer(&self) -> &JsonPointer
Methods from Deref<Target = JsonPointer>§
pub const ROOT: &'static JsonPointer
pub fn as_bytes(&self) -> &[u8] ⓘ
pub fn as_str(&self) -> &str
pub fn is_empty(&self) -> bool
pub fn split_first(&self) -> Option<(&ReferenceToken, &JsonPointer)>
pub fn iter(&self) -> JsonPointerIter<'_> ⓘ
Trait Implementations§
Source§impl AsRef<JsonPointer> for JsonPointerBuf
impl AsRef<JsonPointer> for JsonPointerBuf
Source§fn as_ref(&self) -> &JsonPointer
fn as_ref(&self) -> &JsonPointer
Converts this type into a shared reference of the (usually inferred) input type.
Source§impl Borrow<JsonPointer> for JsonPointerBuf
impl Borrow<JsonPointer> for JsonPointerBuf
Source§fn borrow(&self) -> &JsonPointer
fn borrow(&self) -> &JsonPointer
Immutably borrows from an owned value. Read more
Source§impl Clone for JsonPointerBuf
impl Clone for JsonPointerBuf
Source§fn clone(&self) -> JsonPointerBuf
fn clone(&self) -> JsonPointerBuf
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for JsonPointerBuf
impl Debug for JsonPointerBuf
Source§impl Default for JsonPointerBuf
impl Default for JsonPointerBuf
Source§fn default() -> JsonPointerBuf
fn default() -> JsonPointerBuf
Returns the “default value” for a type. Read more
Source§impl Deref for JsonPointerBuf
impl Deref for JsonPointerBuf
Source§type Target = JsonPointer
type Target = JsonPointer
The resulting type after dereferencing.
Source§impl<'de> Deserialize<'de> for JsonPointerBuf
impl<'de> Deserialize<'de> for JsonPointerBuf
Source§fn deserialize<D>(
deserializer: D,
) -> Result<JsonPointerBuf, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
fn deserialize<D>(
deserializer: D,
) -> Result<JsonPointerBuf, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Display for JsonPointerBuf
impl Display for JsonPointerBuf
Source§impl FromStr for JsonPointerBuf
impl FromStr for JsonPointerBuf
Source§type Err = InvalidJsonPointer
type Err = InvalidJsonPointer
The associated error which can be returned from parsing.
Source§fn from_str(s: &str) -> Result<JsonPointerBuf, <JsonPointerBuf as FromStr>::Err>
fn from_str(s: &str) -> Result<JsonPointerBuf, <JsonPointerBuf as FromStr>::Err>
Parses a string
s to return a value of this type. Read moreSource§impl Hash for JsonPointerBuf
impl Hash for JsonPointerBuf
Source§impl Ord for JsonPointerBuf
impl Ord for JsonPointerBuf
Source§fn cmp(&self, other: &JsonPointerBuf) -> Ordering
fn cmp(&self, other: &JsonPointerBuf) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for JsonPointerBuf
impl PartialEq for JsonPointerBuf
Source§impl PartialOrd for JsonPointerBuf
impl PartialOrd for JsonPointerBuf
Source§impl Serialize for JsonPointerBuf
impl Serialize for JsonPointerBuf
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
Source§impl TryFrom<String> for JsonPointerBuf
impl TryFrom<String> for JsonPointerBuf
Source§type Error = InvalidJsonPointer
type Error = InvalidJsonPointer
The type returned in the event of a conversion error.
Source§fn try_from(
value: String,
) -> Result<JsonPointerBuf, <JsonPointerBuf as TryFrom<String>>::Error>
fn try_from( value: String, ) -> Result<JsonPointerBuf, <JsonPointerBuf as TryFrom<String>>::Error>
Performs the conversion.
impl Eq for JsonPointerBuf
impl StructuralPartialEq for JsonPointerBuf
Auto Trait Implementations§
impl Freeze for JsonPointerBuf
impl RefUnwindSafe for JsonPointerBuf
impl Send for JsonPointerBuf
impl Sync for JsonPointerBuf
impl Unpin for JsonPointerBuf
impl UnwindSafe for JsonPointerBuf
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> BorrowUnordered for T
impl<T> BorrowUnordered for T
fn as_unordered(&self) -> &Unordered<T>
Source§impl<T> CallHasher for T
impl<T> CallHasher for T
Source§impl<T> Clear for Twhere
T: InitializableFromZeroed + ?Sized,
impl<T> Clear for Twhere
T: InitializableFromZeroed + ?Sized,
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<'de, T, C> DeserializeTyped<'de, C> for Twhere
T: Deserialize<'de>,
impl<'de, T, C> DeserializeTyped<'de, C> for Twhere
T: Deserialize<'de>,
fn deserialize_typed<S>(
_: &C,
deserializer: S,
) -> Result<T, <S as Deserializer<'de>>::Error>where
S: Deserializer<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
fn equivalent(&self, key: &K) -> bool
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<T> InitializableFromZeroed for Twhere
T: Default,
impl<T> InitializableFromZeroed for Twhere
T: Default,
Source§unsafe fn initialize(place: *mut T)
unsafe fn initialize(place: *mut T)
Called to initialize a place to a valid value, after it is set
to all-bits-zero. Read more
Source§impl<T, U, C> IntoWithContext<U, C> for Twhere
U: FromWithContext<T, C>,
impl<T, U, C> IntoWithContext<U, C> for Twhere
U: FromWithContext<T, C>,
Source§impl<T> ResourceProvider<()> for T
impl<T> ResourceProvider<()> for T
Source§fn get_resource(&self) -> &()
fn get_resource(&self) -> &()
Returns a reference to the resource of type
T.