[][src]Struct json_surf::registry::Surfer

pub struct Surfer { /* fields omitted */ }

Surfer: Client API

Implementations

impl Surfer[src]

pub fn home(&self) -> &String[src]

Location of home

pub fn which_index(&self, name: &str) -> Option<String>[src]

Location of Index

pub fn insert_struct<T: Serialize>(
    &mut self,
    name: &str,
    data: &T
) -> Result<(), IndexError>
[src]

Inserts a struct

pub fn insert_structs<T: Serialize>(
    &mut self,
    name: &str,
    payload: &Vec<T>
) -> Result<(), IndexError>
[src]

Inserts a structs

pub fn read_string(
    &mut self,
    name: &str,
    query: &str,
    limit: Option<usize>,
    score: Option<f32>
) -> Result<Option<Vec<String>>, IndexError>
[src]

Reads as string

pub fn read_structs<T: Serialize + DeserializeOwned>(
    &mut self,
    name: &str,
    query: &str,
    limit: Option<usize>,
    score: Option<f32>
) -> Result<Option<Vec<T>>, IndexError>
[src]

Reads as struct

impl Surfer[src]

Panics if somethings goes wrong

pub fn new(builder: SurferBuilder) -> Self[src]

Trait Implementations

impl TryFrom<SurferBuilder> for Surfer[src]

type Error = IndexError

The type returned in the event of a conversion error.

Auto Trait Implementations

impl !RefUnwindSafe for Surfer

impl Send for Surfer

impl Sync for Surfer

impl Unpin for Surfer

impl !UnwindSafe for Surfer

Blanket Implementations

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

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

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

impl<T> Downcast for T where
    T: Any

impl<T> DowncastSync for T where
    T: Send + Sync + Any

impl<T> Erased for T

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

impl<T> Fruit for T where
    T: Send + Downcast, 
[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<V, T> VZip<V> for T where
    V: MultiLane<T>,