Trait parity_rpc::v1::EthPubSub
source · [−]pub trait EthPubSub: Sized + Send + Sync + 'static {
type Metadata: PubSubMetadata;
fn subscribe(
&self,
_: Self::Metadata,
_: Subscriber<Result>,
_: Kind,
_: Option<Params>
);
fn unsubscribe(
&self,
_: Option<Self::Metadata>,
_: SubscriptionId
) -> Result<bool>;
fn to_delegate(self) -> IoDelegate<Self, Self::Metadata> { ... }
}
Expand description
Eth PUB-SUB rpc interface.
Associated Types
type Metadata: PubSubMetadata
type Metadata: PubSubMetadata
RPC Metadata
Required methods
fn subscribe(
&self,
_: Self::Metadata,
_: Subscriber<Result>,
_: Kind,
_: Option<Params>
)
fn subscribe(
&self,
_: Self::Metadata,
_: Subscriber<Result>,
_: Kind,
_: Option<Params>
)
Subscribe to Eth subscription.
fn unsubscribe(
&self,
_: Option<Self::Metadata>,
_: SubscriptionId
) -> Result<bool>
fn unsubscribe(
&self,
_: Option<Self::Metadata>,
_: SubscriptionId
) -> Result<bool>
Unsubscribe from existing Eth subscription.
Provided methods
fn 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.