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

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

Performs the conversion.

impl From<String> for OptionVal
[src]

Performs the conversion.

impl From<i32> for OptionVal
[src]

Performs the conversion.

impl From<i64> for OptionVal
[src]

Performs the conversion.

impl From<u32> for OptionVal
[src]

Performs the conversion.

impl From<u64> for OptionVal
[src]

Performs the conversion.

impl From<bool> for OptionVal
[src]

Performs the conversion.

impl From<VersionType> for OptionVal
[src]

Performs the conversion.

impl From<Consistency> for OptionVal
[src]

Performs the conversion.

impl From<DefaultOperator> for OptionVal
[src]

Performs the conversion.

impl From<Preference> for OptionVal
[src]

Performs the conversion.

impl From<OpType> for OptionVal
[src]

Performs the conversion.

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);

Performs the conversion.

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

Performs the conversion.

impl From<Duration> for OptionVal
[src]

Performs the conversion.