[][src]Struct rs_es::operations::common::OptionVal

pub struct OptionVal(pub String);

A newtype for the value of a URI option, this is to allow conversion traits to be implemented for it

Trait Implementations

impl<'a> From<&'a str> for OptionVal[src]

Conversion from &str to OptionVal

impl From<String> for OptionVal[src]

impl From<i32> for OptionVal[src]

impl From<i64> for OptionVal[src]

impl From<u32> for OptionVal[src]

impl From<u64> for OptionVal[src]

impl From<bool> for OptionVal[src]

impl From<VersionType> for OptionVal[src]

impl From<Consistency> for OptionVal[src]

impl From<DefaultOperator> for OptionVal[src]

impl From<Preference> for OptionVal[src]

impl From<OpType> for OptionVal[src]

impl<'a> From<&'a Sort> for OptionVal[src]

Conversion of a Sort into an OptionVal for use in search-by-URI queries

use rs_es::operations::common::OptionVal;
use rs_es::operations::search::{Sort, SortField, Order};
let sort = Sort::new(vec![SortField::new("a", Some(Order::Asc)).build(),
                                    SortField::new("b", None).build()]);
let op_val:OptionVal = (&sort).into();
assert_eq!("a:asc,b", op_val.0);

impl<'a> From<&'a Duration> for OptionVal[src]

impl From<Duration> for OptionVal[src]

impl Debug for OptionVal[src]

Auto Trait Implementations

Blanket Implementations

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Erased for T

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 

type Err = <U as TryFrom<T>>::Err