[][src]Struct romad::client::RomadClient

pub struct RomadClient { /* fields omitted */ }

Implementations

impl RomadClient[src]

pub fn new(
    address: &'static str,
    port: &'static str,
    token: Option<&'static str>
) -> Result<RomadClient, RomadClientError>
[src]

New

pub fn from_connection(
    connection: Connection<'_>
) -> Result<RomadClient, RomadClientError>
[src]

Create client from a connection object

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

Get base url

pub fn get_client(&self) -> &Client[src]

Get the http client for then object

pub async fn list_jobs<'_, '_, '_>(
    &'_ mut self,
    prefix: Option<&'_ String>,
    namespace: Option<&'_ String>
) -> Result<Vec<Job>, RomadClientError>
[src]

Method calls the List Jobs endpoint TODO: Implement prefix and namespace filter

Auto Trait Implementations

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> From<T> for T[src]

impl<T> Instrument 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.