pub trait Agent: Sized {
// Required methods
fn new(url: String) -> AtpAgent;
fn login<'async_trait>(
self,
identifier: String,
password: String,
) -> Pin<Box<dyn Future<Output = Result<AtpAgent, Box<dyn Error>>> + Send + 'async_trait>>
where Self: 'async_trait;
fn refresh_session<'async_trait>(
self,
) -> Pin<Box<dyn Future<Output = Result<(), Box<dyn Error>>> + Send + 'async_trait>>
where Self: 'async_trait;
fn get<'async_trait>(
self,
lexicon: String,
parameters: Value,
) -> Pin<Box<dyn Future<Output = Result<Value, Box<dyn Error>>> + Send + 'async_trait>>
where Self: 'async_trait;
}
Required Methods§
fn new(url: String) -> AtpAgent
fn login<'async_trait>(
self,
identifier: String,
password: String,
) -> Pin<Box<dyn Future<Output = Result<AtpAgent, Box<dyn Error>>> + Send + 'async_trait>>where
Self: 'async_trait,
fn refresh_session<'async_trait>(
self,
) -> Pin<Box<dyn Future<Output = Result<(), Box<dyn Error>>> + Send + 'async_trait>>where
Self: 'async_trait,
fn get<'async_trait>(
self,
lexicon: String,
parameters: Value,
) -> Pin<Box<dyn Future<Output = Result<Value, Box<dyn Error>>> + Send + 'async_trait>>where
Self: 'async_trait,
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.