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

pub struct RomadClient { /* fields omitted */ }


impl RomadClient[src]

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


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

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>

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

impl<T> Borrow<T> for T where
    T: ?Sized

impl<T> BorrowMut<T> for T where
    T: ?Sized

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

impl<T> Instrument for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 

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>,