Struct ethcore_rpc::v1::tests::helpers::TestFetch
[−]
[src]
pub struct TestFetch;
Test implementation of fetcher. Will always return the same file.
Trait Implementations
impl Default for TestFetch
[src]
impl Clone for TestFetch
[src]
fn clone(&self) -> TestFetch
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more
impl Fetch for TestFetch
[src]
type Result = BoxFuture<Response, Error>
fn new() -> Result<Self, Error> where Self: Sized
fn fetch_with_abort(&self, _url: &str, _abort: Abort) -> Self::Result
Fetch URL and get a future for the result. Supports aborting the request in the middle of execution. Read more
fn process<F, I, E>(&self,
f: F)
-> Box<Future<Error=E, Item=I> + 'static + Send> where E: Send + 'static, F: Future<Item=I, Error=E> + Send + 'static, I: Send + 'static
f: F)
-> Box<Future<Error=E, Item=I> + 'static + Send> where E: Send + 'static, F: Future<Item=I, Error=E> + Send + 'static, I: Send + 'static
Spawn the future in context of this Fetch
thread pool. Implementation is optional. Read more
fn fetch(&self, url: &str) -> Self::Result
Fetch URL and get a future for the result.
fn fetch_sync(&self, url: &str) -> Result<Response, Error>
Fetch URL and get the result synchronously.
fn close(self)
Closes this client