Added method to specify host of raw client
This commit is contained in:
parent
2fcfbe9e67
commit
4003dfe246
|
@ -39,6 +39,12 @@ pub fn new() -> Client {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub fn with_host(host: &str) -> Client {
|
||||||
|
Client {
|
||||||
|
client: jsonrpc2_client::new(&host),
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
impl Client {
|
impl Client {
|
||||||
pub async fn send_request<T: serde::de::DeserializeOwned + std::fmt::Debug>(
|
pub async fn send_request<T: serde::de::DeserializeOwned + std::fmt::Debug>(
|
||||||
&self,
|
&self,
|
||||||
|
|
Loading…
Reference in New Issue