pub trait Get {
type Error;
type Input;
type Output<'output>
where Self: 'output;
// Required method
fn get(&self, input: Self::Input) -> Result<Self::Output<'_>, Self::Error>;
}Expand description
See Get::get for more information.
Required Associated Types§
Required Methods§
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.
Implementations on Foreign Types§
Source§impl<T> Get for &[T]
let structure = cl_aux::doc_tests::slice();
assert_eq!(cl_aux::Get::get(&structure, 0), Ok(&1));
impl<T> Get for &[T]
let structure = cl_aux::doc_tests::slice();
assert_eq!(cl_aux::Get::get(&structure, 0), Ok(&1));Source§impl<T> Get for &mut [T]
let mut structure = cl_aux::doc_tests::slice_mut!();
assert_eq!(cl_aux::Get::get(&mut structure, 0), Ok(&1));
impl<T> Get for &mut [T]
let mut structure = cl_aux::doc_tests::slice_mut!();
assert_eq!(cl_aux::Get::get(&mut structure, 0), Ok(&1));Source§impl<T, const N: usize> Get for [T; N]
let structure = cl_aux::doc_tests::array();
assert_eq!(cl_aux::Get::get(&structure, 0), Ok(&1));
impl<T, const N: usize> Get for [T; N]
let structure = cl_aux::doc_tests::array();
assert_eq!(cl_aux::Get::get(&structure, 0), Ok(&1));