[][src]Struct bigml::Client

pub struct Client { /* fields omitted */ }

A client connection to BigML.

Methods

impl Client[src]

pub fn new<S1, S2>(username: S1, api_key: S2) -> Result<Client> where
    S1: Into<String>,
    S2: Into<String>, 
[src]

Create a new Client.

pub fn create<Args>(&self, args: &Args) -> Result<Args::Resource> where
    Args: Args
[src]

Create a new resource.

pub fn create_and_wait<Args>(&self, args: &Args) -> Result<Args::Resource> where
    Args: Args
[src]

Create a new resource, and wait until it is ready.

pub fn create_source_from_path<P>(&self, path: P) -> Result<Source> where
    P: AsRef<Path>, 
[src]

Create a BigML data source using data from the specified path. We stream the data over the network without trying to load it all into memory.

pub fn create_source_from_path_and_wait<P>(&self, path: P) -> Result<Source> where
    P: AsRef<Path>, 
[src]

Create a BigML data source using data from the specified path. We stream the data over the network without trying to load it all into memory.

pub fn update<R: Resource + Updatable>(
    &self,
    resource: &Id<R>,
    update: &<R as Updatable>::Update
) -> Result<()>
[src]

Update the specified resource using update. We do not return the updated resource because of peculiarities with BigML's API, but you can always use Client::fetch if you need the updated version.

pub fn fetch<R: Resource>(&self, resource: &Id<R>) -> Result<R>[src]

Fetch an existing resource.

pub fn wait<R: Resource>(&self, resource: &Id<R>) -> Result<R>[src]

Poll an existing resource, returning it once it's ready.

pub fn wait_opt<'a, R: Resource>(
    &self,
    resource: &Id<R>,
    wait_options: &WaitOptions,
    progress_options: &mut ProgressOptions<'a, R>
) -> Result<R>
[src]

Poll an existing resource, returning it once it's ready, and honoring wait and progress options.

pub fn download<R: Resource>(&self, resource: &Id<R>) -> Result<Response>[src]

Download a resource as a CSV file. This only makes sense for certain kinds of resources.

pub fn download_opt<R: Resource>(
    &self,
    resource: &Id<R>,
    options: &WaitOptions
) -> Result<Response>
[src]

Download a resource as a CSV file. This only makes sense for certain kinds of resources.

pub fn delete<R: Resource>(&self, resource: &Id<R>) -> Result<()>[src]

Delete the specified resource.

Auto Trait Implementations

impl Sync for Client

impl Send for Client

impl Unpin for Client

impl RefUnwindSafe for Client

impl UnwindSafe for Client

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