[][src]Struct rs_es::operations::bulk::Action

pub struct Action<X>(_, _);

Methods

impl<S> Action<S> where
    S: Serialize
[src]

pub fn index(document: S) -> Self[src]

An index action.

Takes the document to be indexed, other parameters can be set as optional on the Action struct returned.

pub fn create(document: S) -> Self[src]

Create action

impl<S> Action<S>[src]

pub fn delete<A: Into<String>>(id: A) -> Self[src]

Delete a document based on ID.

Example

use rs_es::operations::bulk::Action;

let delete_action:Action<()> = Action::delete("doc_id");
let delete_with_index:Action<()> = Action::delete("doc_id").with_index("index_name");

pub fn with_index<T: Into<String>>(self, val: T) -> Self[src]

pub fn with_doc_type<T: Into<String>>(self, val: T) -> Self[src]

pub fn with_id<T: Into<String>>(self, val: T) -> Self[src]

pub fn with_version<T: Into<u64>>(self, val: T) -> Self[src]

pub fn with_version_type<T: Into<VersionType>>(self, val: T) -> Self[src]

pub fn with_routing<T: Into<String>>(self, val: T) -> Self[src]

pub fn with_parent<T: Into<String>>(self, val: T) -> Self[src]

pub fn with_timestamp<T: Into<String>>(self, val: T) -> Self[src]

pub fn with_ttl<T: Into<Duration>>(self, val: T) -> Self[src]

pub fn with_retry_on_conflict<T: Into<u64>>(self, val: T) -> Self[src]

Trait Implementations

impl<X: Debug> Debug for Action<X>[src]

impl<X> Serialize for Action<X> where
    X: Serialize
[src]

Auto Trait Implementations

impl<X> Send for Action<X> where
    X: Send

impl<X> Sync for Action<X> where
    X: Sync

Blanket Implementations

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

impl<T> From<T> for 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> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<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