Struct marketstack::Marketstack
source · pub struct Marketstack { /* private fields */ }
Expand description
A representation of the Marketstack API.
Implementations§
source§impl Marketstack
impl Marketstack
sourcepub fn new<H, T>(host: H, token: T) -> Result<Self, MarketstackError>where
H: AsRef<str>,
T: Into<String>,
pub fn new<H, T>(host: H, token: T) -> Result<Self, MarketstackError>where H: AsRef<str>, T: Into<String>,
Create a new Marketstack API representation.
The token
should be a valid personal access token.
Errors out if token
is invalid.
sourcepub fn new_insecure<H, T>(host: H, token: T) -> Result<Self, MarketstackError>where
H: AsRef<str>,
T: Into<String>,
pub fn new_insecure<H, T>(host: H, token: T) -> Result<Self, MarketstackError>where H: AsRef<str>, T: Into<String>,
Create a new non-SSL Marketstack API representation.
A token
will still be required for insecure access.
Trait Implementations§
source§impl Client for Marketstack
impl Client for Marketstack
source§impl Clone for Marketstack
impl Clone for Marketstack
source§fn clone(&self) -> Marketstack
fn clone(&self) -> Marketstack
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for Marketstack
impl Debug for Marketstack
source§impl RestClient for Marketstack
impl RestClient for Marketstack
Auto Trait Implementations§
impl !RefUnwindSafe for Marketstack
impl Send for Marketstack
impl Sync for Marketstack
impl Unpin for Marketstack
impl !UnwindSafe for Marketstack
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more