Struct parity_rpc::v1::PubSubClient
source · [−]pub struct PubSubClient<S: Middleware<Metadata>> { /* private fields */ }
Expand description
Parity PubSub implementation.
Implementations
sourceimpl<S: Middleware<Metadata>> PubSubClient<S>
impl<S: Middleware<Metadata>> PubSubClient<S>
sourcepub fn new(rpc: MetaIoHandler<Metadata, S>, executor: Executor) -> Self
pub fn new(rpc: MetaIoHandler<Metadata, S>, executor: Executor) -> Self
Creates new PubSubClient
.
Trait Implementations
sourceimpl<S: Middleware<Metadata>> PubSub for PubSubClient<S>
impl<S: Middleware<Metadata>> PubSub for PubSubClient<S>
sourcefn parity_subscribe(
&self,
meta: Metadata,
subscriber: Subscriber<Value>,
method: String,
params: Option<Params>
)
fn parity_subscribe(
&self,
meta: Metadata,
subscriber: Subscriber<Value>,
method: String,
params: Option<Params>
)
Subscribe to changes of any RPC method in Parity.
sourcefn parity_unsubscribe(
&self,
_: Option<Self::Metadata>,
id: SubscriptionId
) -> Result<bool>
fn parity_unsubscribe(
&self,
_: Option<Self::Metadata>,
id: SubscriptionId
) -> Result<bool>
Unsubscribe from existing Parity subscription.
sourcefn to_delegate(self) -> IoDelegate<Self, Self::Metadata>
fn to_delegate(self) -> IoDelegate<Self, Self::Metadata>
Create an IoDelegate
, wiring rpc calls to the trait methods.
Auto Trait Implementations
impl<S> !RefUnwindSafe for PubSubClient<S>
impl<S> Send for PubSubClient<S>
impl<S> Sync for PubSubClient<S>
impl<S> Unpin for PubSubClient<S>
impl<S> !UnwindSafe for PubSubClient<S>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more