simd_json::prelude

Trait ValueObjectAccessAsArray

Source
pub trait ValueObjectAccessAsArray {
    type Key: ?Sized;
    type Array: Array;

    // Required method
    fn get_array<Q>(&self, k: &Q) -> Option<&Self::Array>
       where Self::Key: Borrow<Q>,
             Q: Hash + Eq + Ord + ?Sized;
}
Expand description

Access to array values in an object

Required Associated Types§

Source

type Key: ?Sized

The type for Objects

Source

type Array: Array

The array structure

Required Methods§

Source

fn get_array<Q>(&self, k: &Q) -> Option<&Self::Array>
where Self::Key: Borrow<Q>, Q: Hash + Eq + Ord + ?Sized,

Tries to get an element of an object as a array

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§