pub struct RelayChainRpcClient { /* private fields */ }
Expand description
Client that maps RPC methods and deserializes results
Implementations§
source§impl RelayChainRpcClient
impl RelayChainRpcClient
sourcepub async fn call_remote_runtime_function_encoded(
&self,
method_name: &str,
hash: RelayHash,
payload: &[u8],
) -> RelayChainResult<Bytes>
pub async fn call_remote_runtime_function_encoded( &self, method_name: &str, hash: RelayHash, payload: &[u8], ) -> RelayChainResult<Bytes>
Same as call_remote_runtime_function
but work on encoded data
sourcepub async fn call_remote_runtime_function<R: Decode>(
&self,
method_name: &str,
hash: RelayHash,
payload: Option<impl Encode>,
) -> RelayChainResult<R>
pub async fn call_remote_runtime_function<R: Decode>( &self, method_name: &str, hash: RelayHash, payload: Option<impl Encode>, ) -> RelayChainResult<R>
Call a call to state_call
rpc method.
sourcepub async fn babe_api_current_epoch(
&self,
at: RelayHash,
) -> Result<Epoch, RelayChainError>
pub async fn babe_api_current_epoch( &self, at: RelayHash, ) -> Result<Epoch, RelayChainError>
Returns information regarding the current epoch.
sourcepub async fn parachain_host_on_chain_votes(
&self,
at: RelayHash,
) -> Result<Option<ScrapedOnChainVotes<RelayHash>>, RelayChainError>
pub async fn parachain_host_on_chain_votes( &self, at: RelayHash, ) -> Result<Option<ScrapedOnChainVotes<RelayHash>>, RelayChainError>
Scrape dispute relevant from on-chain, backing votes and resolved disputes.
sourcepub async fn parachain_host_pvfs_require_precheck(
&self,
at: RelayHash,
) -> Result<Vec<ValidationCodeHash>, RelayChainError>
pub async fn parachain_host_pvfs_require_precheck( &self, at: RelayHash, ) -> Result<Vec<ValidationCodeHash>, RelayChainError>
Returns code hashes of PVFs that require pre-checking by validators in the active set.
sourcepub async fn parachain_host_submit_pvf_check_statement(
&self,
at: RelayHash,
stmt: PvfCheckStatement,
signature: ValidatorSignature,
) -> Result<(), RelayChainError>
pub async fn parachain_host_submit_pvf_check_statement( &self, at: RelayHash, stmt: PvfCheckStatement, signature: ValidatorSignature, ) -> Result<(), RelayChainError>
Submits a PVF pre-checking statement into the transaction pool.
sourcepub async fn system_health(&self) -> Result<Health, RelayChainError>
pub async fn system_health(&self) -> Result<Health, RelayChainError>
Get system health information
sourcepub async fn state_get_read_proof(
&self,
storage_keys: Vec<StorageKey>,
at: Option<RelayHash>,
) -> Result<ReadProof<RelayHash>, RelayChainError>
pub async fn state_get_read_proof( &self, storage_keys: Vec<StorageKey>, at: Option<RelayHash>, ) -> Result<ReadProof<RelayHash>, RelayChainError>
Get read proof for storage_keys
sourcepub async fn state_get_storage(
&self,
storage_key: StorageKey,
at: Option<RelayHash>,
) -> Result<Option<StorageData>, RelayChainError>
pub async fn state_get_storage( &self, storage_key: StorageKey, at: Option<RelayHash>, ) -> Result<Option<StorageData>, RelayChainError>
Retrieve storage item at storage_key
sourcepub async fn chain_get_head(
&self,
at: Option<u64>,
) -> Result<RelayHash, RelayChainError>
pub async fn chain_get_head( &self, at: Option<u64>, ) -> Result<RelayHash, RelayChainError>
Get hash of the n-th block in the canon chain.
By default returns latest block hash.
sourcepub async fn parachain_host_validator_groups(
&self,
at: RelayHash,
) -> Result<(Vec<Vec<ValidatorIndex>>, GroupRotationInfo), RelayChainError>
pub async fn parachain_host_validator_groups( &self, at: RelayHash, ) -> Result<(Vec<Vec<ValidatorIndex>>, GroupRotationInfo), RelayChainError>
Returns the validator groups and rotation info localized based on the hypothetical child
of a block whose state this is invoked on. Note that now
in the GroupRotationInfo
should be the successor of the number of the block.
sourcepub async fn parachain_host_candidate_events(
&self,
at: RelayHash,
) -> Result<Vec<CandidateEvent>, RelayChainError>
pub async fn parachain_host_candidate_events( &self, at: RelayHash, ) -> Result<Vec<CandidateEvent>, RelayChainError>
Get a vector of events concerning candidates that occurred within a block.
sourcepub async fn parachain_host_check_validation_outputs(
&self,
at: RelayHash,
para_id: ParaId,
outputs: CandidateCommitments,
) -> Result<bool, RelayChainError>
pub async fn parachain_host_check_validation_outputs( &self, at: RelayHash, para_id: ParaId, outputs: CandidateCommitments, ) -> Result<bool, RelayChainError>
Checks if the given validation outputs pass the acceptance criteria.
sourcepub async fn parachain_host_assumed_validation_data(
&self,
at: RelayHash,
para_id: ParaId,
expected_hash: RelayHash,
) -> Result<Option<(PersistedValidationData, ValidationCodeHash)>, RelayChainError>
pub async fn parachain_host_assumed_validation_data( &self, at: RelayHash, para_id: ParaId, expected_hash: RelayHash, ) -> Result<Option<(PersistedValidationData, ValidationCodeHash)>, RelayChainError>
Returns the persisted validation data for the given ParaId
along with the corresponding
validation code hash. Instead of accepting assumption about the para, matches the validation
data hash against an expected one and yields None
if they’re not equal.
sourcepub async fn chain_get_finalized_head(
&self,
) -> Result<RelayHash, RelayChainError>
pub async fn chain_get_finalized_head( &self, ) -> Result<RelayHash, RelayChainError>
Get hash of last finalized block.
sourcepub async fn chain_get_block_hash(
&self,
block_number: Option<BlockNumber>,
) -> Result<Option<RelayHash>, RelayChainError>
pub async fn chain_get_block_hash( &self, block_number: Option<BlockNumber>, ) -> Result<Option<RelayHash>, RelayChainError>
Get hash of n-th block.
sourcepub async fn parachain_host_persisted_validation_data(
&self,
at: RelayHash,
para_id: ParaId,
occupied_core_assumption: OccupiedCoreAssumption,
) -> Result<Option<PersistedValidationData>, RelayChainError>
pub async fn parachain_host_persisted_validation_data( &self, at: RelayHash, para_id: ParaId, occupied_core_assumption: OccupiedCoreAssumption, ) -> Result<Option<PersistedValidationData>, RelayChainError>
Yields the persisted validation data for the given ParaId
along with an assumption that
should be used if the para currently occupies a core.
Returns None
if either the para is not registered or the assumption is Freed
and the para already occupies a core.
sourcepub async fn parachain_host_validation_code_by_hash(
&self,
at: RelayHash,
validation_code_hash: ValidationCodeHash,
) -> Result<Option<ValidationCode>, RelayChainError>
pub async fn parachain_host_validation_code_by_hash( &self, at: RelayHash, validation_code_hash: ValidationCodeHash, ) -> Result<Option<ValidationCode>, RelayChainError>
Get the validation code from its hash.
sourcepub async fn parachain_host_availability_cores(
&self,
at: RelayHash,
) -> Result<Vec<CoreState<RelayHash, BlockNumber>>, RelayChainError>
pub async fn parachain_host_availability_cores( &self, at: RelayHash, ) -> Result<Vec<CoreState<RelayHash, BlockNumber>>, RelayChainError>
Yields information on all availability cores as relevant to the child block. Cores are either free or occupied. Free cores can have paras assigned to them.
sourcepub async fn runtime_version(
&self,
at: RelayHash,
) -> Result<RuntimeVersion, RelayChainError>
pub async fn runtime_version( &self, at: RelayHash, ) -> Result<RuntimeVersion, RelayChainError>
Get runtime version
sourcepub async fn parachain_host_disputes(
&self,
at: RelayHash,
) -> Result<Vec<(SessionIndex, CandidateHash, DisputeState<BlockNumber>)>, RelayChainError>
pub async fn parachain_host_disputes( &self, at: RelayHash, ) -> Result<Vec<(SessionIndex, CandidateHash, DisputeState<BlockNumber>)>, RelayChainError>
Returns all onchain disputes.
sourcepub async fn parachain_host_unapplied_slashes(
&self,
at: RelayHash,
) -> Result<Vec<(SessionIndex, CandidateHash, PendingSlashes)>, RelayChainError>
pub async fn parachain_host_unapplied_slashes( &self, at: RelayHash, ) -> Result<Vec<(SessionIndex, CandidateHash, PendingSlashes)>, RelayChainError>
Returns a list of validators that lost a past session dispute and need to be slashed.
This is a staging method! Do not use on production runtimes!
sourcepub async fn parachain_host_key_ownership_proof(
&self,
at: RelayHash,
validator_id: ValidatorId,
) -> Result<Option<OpaqueKeyOwnershipProof>, RelayChainError>
pub async fn parachain_host_key_ownership_proof( &self, at: RelayHash, validator_id: ValidatorId, ) -> Result<Option<OpaqueKeyOwnershipProof>, RelayChainError>
Returns a merkle proof of a validator session key in a past session.
This is a staging method! Do not use on production runtimes!
sourcepub async fn parachain_host_submit_report_dispute_lost(
&self,
at: RelayHash,
dispute_proof: DisputeProof,
key_ownership_proof: OpaqueKeyOwnershipProof,
) -> Result<Option<()>, RelayChainError>
pub async fn parachain_host_submit_report_dispute_lost( &self, at: RelayHash, dispute_proof: DisputeProof, key_ownership_proof: OpaqueKeyOwnershipProof, ) -> Result<Option<()>, RelayChainError>
Submits an unsigned extrinsic to slash validators who lost a dispute about a candidate of a past session.
This is a staging method! Do not use on production runtimes!
sourcepub async fn parachain_host_validation_code(
&self,
at: RelayHash,
para_id: ParaId,
occupied_core_assumption: OccupiedCoreAssumption,
) -> Result<Option<ValidationCode>, RelayChainError>
pub async fn parachain_host_validation_code( &self, at: RelayHash, para_id: ParaId, occupied_core_assumption: OccupiedCoreAssumption, ) -> Result<Option<ValidationCode>, RelayChainError>
Fetch the validation code used by a para, making the given OccupiedCoreAssumption
.
Returns None
if either the para is not registered or the assumption is Freed
and the para already occupies a core.
sourcepub async fn parachain_host_validation_code_hash(
&self,
at: RelayHash,
para_id: ParaId,
occupied_core_assumption: OccupiedCoreAssumption,
) -> Result<Option<ValidationCodeHash>, RelayChainError>
pub async fn parachain_host_validation_code_hash( &self, at: RelayHash, para_id: ParaId, occupied_core_assumption: OccupiedCoreAssumption, ) -> Result<Option<ValidationCodeHash>, RelayChainError>
Fetch the hash of the validation code used by a para, making the given
OccupiedCoreAssumption
.
sourcepub async fn parachain_host_session_info(
&self,
at: RelayHash,
index: SessionIndex,
) -> Result<Option<SessionInfo>, RelayChainError>
pub async fn parachain_host_session_info( &self, at: RelayHash, index: SessionIndex, ) -> Result<Option<SessionInfo>, RelayChainError>
Get the session info for the given session, if stored.
sourcepub async fn parachain_host_session_executor_params(
&self,
at: RelayHash,
session_index: SessionIndex,
) -> Result<Option<ExecutorParams>, RelayChainError>
pub async fn parachain_host_session_executor_params( &self, at: RelayHash, session_index: SessionIndex, ) -> Result<Option<ExecutorParams>, RelayChainError>
Get the executor parameters for the given session, if stored
sourcepub async fn chain_get_header(
&self,
hash: Option<RelayHash>,
) -> Result<Option<RelayHeader>, RelayChainError>
pub async fn chain_get_header( &self, hash: Option<RelayHash>, ) -> Result<Option<RelayHeader>, RelayChainError>
Get header at specified hash
sourcepub async fn parachain_host_candidate_pending_availability(
&self,
at: RelayHash,
para_id: ParaId,
) -> Result<Option<CommittedCandidateReceipt>, RelayChainError>
pub async fn parachain_host_candidate_pending_availability( &self, at: RelayHash, para_id: ParaId, ) -> Result<Option<CommittedCandidateReceipt>, RelayChainError>
Get the receipt of a candidate pending availability. This returns Some
for any paras
assigned to occupied cores in availability_cores
and None
otherwise.
sourcepub async fn parachain_host_session_index_for_child(
&self,
at: RelayHash,
) -> Result<SessionIndex, RelayChainError>
pub async fn parachain_host_session_index_for_child( &self, at: RelayHash, ) -> Result<SessionIndex, RelayChainError>
Returns the session index expected at a child of the block.
This can be used to instantiate a SigningContext
.
sourcepub async fn parachain_host_validators(
&self,
at: RelayHash,
) -> Result<Vec<ValidatorId>, RelayChainError>
pub async fn parachain_host_validators( &self, at: RelayHash, ) -> Result<Vec<ValidatorId>, RelayChainError>
Get the current validators.
sourcepub async fn parachain_host_inbound_hrmp_channels_contents(
&self,
para_id: ParaId,
at: RelayHash,
) -> Result<BTreeMap<ParaId, Vec<InboundHrmpMessage>>, RelayChainError>
pub async fn parachain_host_inbound_hrmp_channels_contents( &self, para_id: ParaId, at: RelayHash, ) -> Result<BTreeMap<ParaId, Vec<InboundHrmpMessage>>, RelayChainError>
Get the contents of all channels addressed to the given recipient. Channels that have no messages in them are also included.
sourcepub async fn parachain_host_dmq_contents(
&self,
para_id: ParaId,
at: RelayHash,
) -> Result<Vec<InboundDownwardMessage>, RelayChainError>
pub async fn parachain_host_dmq_contents( &self, para_id: ParaId, at: RelayHash, ) -> Result<Vec<InboundDownwardMessage>, RelayChainError>
Get all the pending inbound messages in the downward message queue for a para.
sourcepub async fn parachain_host_minimum_backing_votes(
&self,
at: RelayHash,
_session_index: SessionIndex,
) -> Result<u32, RelayChainError>
pub async fn parachain_host_minimum_backing_votes( &self, at: RelayHash, _session_index: SessionIndex, ) -> Result<u32, RelayChainError>
Get the minimum number of backing votes for a candidate.
pub async fn parachain_host_node_features( &self, at: RelayHash, ) -> Result<NodeFeatures, RelayChainError>
pub async fn parachain_host_disabled_validators( &self, at: RelayHash, ) -> Result<Vec<ValidatorIndex>, RelayChainError>
pub async fn parachain_host_async_backing_params( &self, at: RelayHash, ) -> Result<AsyncBackingParams, RelayChainError>
pub async fn parachain_host_staging_approval_voting_params( &self, at: RelayHash, _session_index: SessionIndex, ) -> Result<ApprovalVotingParams, RelayChainError>
pub async fn parachain_host_para_backing_state( &self, at: RelayHash, para_id: ParaId, ) -> Result<Option<BackingState>, RelayChainError>
pub async fn parachain_host_claim_queue( &self, at: RelayHash, ) -> Result<BTreeMap<CoreIndex, VecDeque<ParaId>>, RelayChainError>
sourcepub async fn parachain_host_candidates_pending_availability(
&self,
at: RelayHash,
para_id: ParaId,
) -> Result<Vec<CommittedCandidateReceipt>, RelayChainError>
pub async fn parachain_host_candidates_pending_availability( &self, at: RelayHash, para_id: ParaId, ) -> Result<Vec<CommittedCandidateReceipt>, RelayChainError>
Get the receipt of all candidates pending availability.
pub async fn validation_code_hash( &self, at: RelayHash, para_id: ParaId, occupied_core_assumption: OccupiedCoreAssumption, ) -> Result<Option<ValidationCodeHash>, RelayChainError>
sourcepub fn get_imported_heads_stream(
&self,
) -> Result<Receiver<RelayHeader>, RelayChainError>
pub fn get_imported_heads_stream( &self, ) -> Result<Receiver<RelayHeader>, RelayChainError>
Get a stream of all imported relay chain headers
sourcepub fn get_best_heads_stream(
&self,
) -> Result<Receiver<RelayHeader>, RelayChainError>
pub fn get_best_heads_stream( &self, ) -> Result<Receiver<RelayHeader>, RelayChainError>
Get a stream of new best relay chain headers
sourcepub fn get_finalized_heads_stream(
&self,
) -> Result<Receiver<RelayHeader>, RelayChainError>
pub fn get_finalized_heads_stream( &self, ) -> Result<Receiver<RelayHeader>, RelayChainError>
Get a stream of finalized relay chain headers
Trait Implementations§
source§impl Clone for RelayChainRpcClient
impl Clone for RelayChainRpcClient
source§fn clone(&self) -> RelayChainRpcClient
fn clone(&self) -> RelayChainRpcClient
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreAuto Trait Implementations§
impl Freeze for RelayChainRpcClient
impl !RefUnwindSafe for RelayChainRpcClient
impl Send for RelayChainRpcClient
impl Sync for RelayChainRpcClient
impl Unpin for RelayChainRpcClient
impl !UnwindSafe for RelayChainRpcClient
Blanket Implementations§
§impl<T> AnySync for T
impl<T> AnySync for T
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
source§impl<T> CheckedConversion for T
impl<T> CheckedConversion for T
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)§impl<T> Conv for T
impl<T> Conv for T
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s.§impl<T> DowncastSync for T
impl<T> DowncastSync for T
§impl<T> FmtForward for T
impl<T> FmtForward for T
§fn fmt_binary(self) -> FmtBinary<Self>where
Self: Binary,
fn fmt_binary(self) -> FmtBinary<Self>where
Self: Binary,
self
to use its Binary
implementation when Debug
-formatted.§fn fmt_display(self) -> FmtDisplay<Self>where
Self: Display,
fn fmt_display(self) -> FmtDisplay<Self>where
Self: Display,
self
to use its Display
implementation when
Debug
-formatted.§fn fmt_lower_exp(self) -> FmtLowerExp<Self>where
Self: LowerExp,
fn fmt_lower_exp(self) -> FmtLowerExp<Self>where
Self: LowerExp,
self
to use its LowerExp
implementation when
Debug
-formatted.§fn fmt_lower_hex(self) -> FmtLowerHex<Self>where
Self: LowerHex,
fn fmt_lower_hex(self) -> FmtLowerHex<Self>where
Self: LowerHex,
self
to use its LowerHex
implementation when
Debug
-formatted.§fn fmt_octal(self) -> FmtOctal<Self>where
Self: Octal,
fn fmt_octal(self) -> FmtOctal<Self>where
Self: Octal,
self
to use its Octal
implementation when Debug
-formatted.§fn fmt_pointer(self) -> FmtPointer<Self>where
Self: Pointer,
fn fmt_pointer(self) -> FmtPointer<Self>where
Self: Pointer,
self
to use its Pointer
implementation when
Debug
-formatted.§fn fmt_upper_exp(self) -> FmtUpperExp<Self>where
Self: UpperExp,
fn fmt_upper_exp(self) -> FmtUpperExp<Self>where
Self: UpperExp,
self
to use its UpperExp
implementation when
Debug
-formatted.§fn fmt_upper_hex(self) -> FmtUpperHex<Self>where
Self: UpperHex,
fn fmt_upper_hex(self) -> FmtUpperHex<Self>where
Self: UpperHex,
self
to use its UpperHex
implementation when
Debug
-formatted.§fn fmt_list(self) -> FmtList<Self>where
&'a Self: for<'a> IntoIterator,
fn fmt_list(self) -> FmtList<Self>where
&'a Self: for<'a> IntoIterator,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more§impl<Src, Dest> IntoTuple<Dest> for Srcwhere
Dest: FromTuple<Src>,
impl<Src, Dest> IntoTuple<Dest> for Srcwhere
Dest: FromTuple<Src>,
fn into_tuple(self) -> Dest
source§impl<T, Outer> IsWrappedBy<Outer> for T
impl<T, Outer> IsWrappedBy<Outer> for T
§impl<T> Pipe for Twhere
T: ?Sized,
impl<T> Pipe for Twhere
T: ?Sized,
§fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> Rwhere
Self: Sized,
fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> Rwhere
Self: Sized,
§fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> Rwhere
R: 'a,
fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> Rwhere
R: 'a,
self
and passes that borrow into the pipe function. Read more§fn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> Rwhere
R: 'a,
fn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> Rwhere
R: 'a,
self
and passes that borrow into the pipe function. Read more§fn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> R
fn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> R
§fn pipe_borrow_mut<'a, B, R>(
&'a mut self,
func: impl FnOnce(&'a mut B) -> R,
) -> R
fn pipe_borrow_mut<'a, B, R>( &'a mut self, func: impl FnOnce(&'a mut B) -> R, ) -> R
§fn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> R
fn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> R
self
, then passes self.as_ref()
into the pipe function.§fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> R
fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> R
self
, then passes self.as_mut()
into the pipe
function.§fn pipe_deref<'a, T, R>(&'a self, func: impl FnOnce(&'a T) -> R) -> R
fn pipe_deref<'a, T, R>(&'a self, func: impl FnOnce(&'a T) -> R) -> R
self
, then passes self.deref()
into the pipe function.§impl<T> Pointable for T
impl<T> Pointable for T
source§impl<T> SaturatedConversion for T
impl<T> SaturatedConversion for T
source§fn saturated_from<T>(t: T) -> Selfwhere
Self: UniqueSaturatedFrom<T>,
fn saturated_from<T>(t: T) -> Selfwhere
Self: UniqueSaturatedFrom<T>,
source§fn saturated_into<T>(self) -> Twhere
Self: UniqueSaturatedInto<T>,
fn saturated_into<T>(self) -> Twhere
Self: UniqueSaturatedInto<T>,
T
. Read more§impl<T> Tap for T
impl<T> Tap for T
§fn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
fn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
Borrow<B>
of a value. Read more§fn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
fn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
BorrowMut<B>
of a value. Read more§fn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
fn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
AsRef<R>
view of a value. Read more§fn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
fn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
AsMut<R>
view of a value. Read more§fn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
fn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
Deref::Target
of a value. Read more§fn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
fn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
Deref::Target
of a value. Read more§fn tap_dbg(self, func: impl FnOnce(&Self)) -> Self
fn tap_dbg(self, func: impl FnOnce(&Self)) -> Self
.tap()
only in debug builds, and is erased in release builds.§fn tap_mut_dbg(self, func: impl FnOnce(&mut Self)) -> Self
fn tap_mut_dbg(self, func: impl FnOnce(&mut Self)) -> Self
.tap_mut()
only in debug builds, and is erased in release
builds.§fn tap_borrow_dbg<B>(self, func: impl FnOnce(&B)) -> Self
fn tap_borrow_dbg<B>(self, func: impl FnOnce(&B)) -> Self
.tap_borrow()
only in debug builds, and is erased in release
builds.§fn tap_borrow_mut_dbg<B>(self, func: impl FnOnce(&mut B)) -> Self
fn tap_borrow_mut_dbg<B>(self, func: impl FnOnce(&mut B)) -> Self
.tap_borrow_mut()
only in debug builds, and is erased in release
builds.§fn tap_ref_dbg<R>(self, func: impl FnOnce(&R)) -> Self
fn tap_ref_dbg<R>(self, func: impl FnOnce(&R)) -> Self
.tap_ref()
only in debug builds, and is erased in release
builds.§fn tap_ref_mut_dbg<R>(self, func: impl FnOnce(&mut R)) -> Self
fn tap_ref_mut_dbg<R>(self, func: impl FnOnce(&mut R)) -> Self
.tap_ref_mut()
only in debug builds, and is erased in release
builds.§fn tap_deref_dbg<T>(self, func: impl FnOnce(&T)) -> Self
fn tap_deref_dbg<T>(self, func: impl FnOnce(&T)) -> Self
.tap_deref()
only in debug builds, and is erased in release
builds.§impl<T> TryConv for T
impl<T> TryConv for T
source§impl<T, U> TryIntoKey<U> for Twhere
U: TryFromKey<T>,
impl<T, U> TryIntoKey<U> for Twhere
U: TryFromKey<T>,
type Error = <U as TryFromKey<T>>::Error
fn try_into_key(self) -> Result<U, <U as TryFromKey<T>>::Error>
source§impl<S, T> UncheckedInto<T> for Swhere
T: UncheckedFrom<S>,
impl<S, T> UncheckedInto<T> for Swhere
T: UncheckedFrom<S>,
source§fn unchecked_into(self) -> T
fn unchecked_into(self) -> T
unchecked_from
.source§impl<T, S> UniqueSaturatedInto<T> for S
impl<T, S> UniqueSaturatedInto<T> for S
source§fn unique_saturated_into(self) -> T
fn unique_saturated_into(self) -> T
T
.