QueriesClient

Struct QueriesClient 

Source
pub struct QueriesClient<T> { /* private fields */ }

Implementations§

Source§

impl QueriesClient<Channel>

Source

pub async fn connect<D>(dst: D) -> Result<Self, Error>
where D: TryInto<Endpoint>, D::Error: Into<StdError>,

Attempt to create a new client by connecting to a given endpoint.

Source§

impl<T> QueriesClient<T>
where T: GrpcService<BoxBody>, T::Error: Into<StdError>, T::ResponseBody: Body<Data = Bytes> + Send + 'static, <T::ResponseBody as Body>::Error: Into<StdError> + Send,

Source

pub fn new(inner: T) -> Self

Source

pub fn with_origin(inner: T, origin: Uri) -> Self

Source

pub fn with_interceptor<F>( inner: T, interceptor: F, ) -> QueriesClient<InterceptedService<T, F>>
where F: Interceptor, T::ResponseBody: Default, T: Service<Request<BoxBody>, Response = Response<<T as GrpcService<BoxBody>>::ResponseBody>>, <T as Service<Request<BoxBody>>>::Error: Into<StdError> + Send + Sync,

Source

pub fn send_compressed(self, encoding: CompressionEncoding) -> Self

Compress requests with the given encoding.

This requires the server to support it otherwise it might respond with an error.

Source

pub fn accept_compressed(self, encoding: CompressionEncoding) -> Self

Enable decompressing responses.

Source

pub fn max_decoding_message_size(self, limit: usize) -> Self

Limits the maximum size of a decoded message.

Default: 4MB

Source

pub fn max_encoding_message_size(self, limit: usize) -> Self

Limits the maximum size of an encoded message.

Default: usize::MAX

Source

pub async fn get_blocks( &mut self, request: impl IntoRequest<Empty>, ) -> Result<Response<Streaming<ArrivedBlockInfo>>, Status>

Return a stream of blocks that arrive from the time the query is made onward. This can be used to listen for incoming blocks.

Source

pub async fn get_finalized_blocks( &mut self, request: impl IntoRequest<Empty>, ) -> Result<Response<Streaming<FinalizedBlockInfo>>, Status>

Return a stream of blocks that are finalized from the time the query is made onward. This can be used to listen for newly finalized blocks. Note that there is no guarantee that blocks will not be skipped if the client is too slow in processing the stream, however blocks will always be sent by increasing block height.

Source

pub async fn get_account_info( &mut self, request: impl IntoRequest<AccountInfoRequest>, ) -> Result<Response<AccountInfo>, Status>

Retrieve the information about the given account in the given block.

Source

pub async fn get_token_info( &mut self, request: impl IntoRequest<TokenInfoRequest>, ) -> Result<Response<TokenInfo>, Status>

Retrieve the information about the given token in the given block.

Source

pub async fn get_account_list( &mut self, request: impl IntoRequest<BlockHashInput>, ) -> Result<Response<Streaming<AccountAddress>>, Status>

Retrieve the list of accounts that exist at the end of the given block.

Source

pub async fn get_token_list( &mut self, request: impl IntoRequest<BlockHashInput>, ) -> Result<Response<Streaming<TokenId>>, Status>

Retrieve the list of protocol level tokens that exist at the end of the given block.

Source

pub async fn get_module_list( &mut self, request: impl IntoRequest<BlockHashInput>, ) -> Result<Response<Streaming<ModuleRef>>, Status>

Get a list of all smart contract modules. The stream will end when all modules that exist in the state at the end of the given block have been returned.

Source

pub async fn get_ancestors( &mut self, request: impl IntoRequest<AncestorsRequest>, ) -> Result<Response<Streaming<BlockHash>>, Status>

Get a stream of ancestors for the provided block. Starting with the provided block itself, moving backwards until no more ancestors or the requested number of ancestors has been returned.

Source

pub async fn get_module_source( &mut self, request: impl IntoRequest<ModuleSourceRequest>, ) -> Result<Response<VersionedModuleSource>, Status>

Get the source of a smart contract module.

Source

pub async fn get_instance_list( &mut self, request: impl IntoRequest<BlockHashInput>, ) -> Result<Response<Streaming<ContractAddress>>, Status>

Get a list of addresses for all smart contract instances. The stream will end when all instances that exist in the state at the end of the given block has been returned.

Source

pub async fn get_instance_info( &mut self, request: impl IntoRequest<InstanceInfoRequest>, ) -> Result<Response<InstanceInfo>, Status>

Get info about a smart contract instance as it appears at the end of the given block.

Source

pub async fn get_instance_state( &mut self, request: impl IntoRequest<InstanceInfoRequest>, ) -> Result<Response<Streaming<InstanceStateKvPair>>, Status>

Get the exact state of a specific contract instance, streamed as a list of key-value pairs. The list is streamed in lexicographic order of keys.

Source

pub async fn instance_state_lookup( &mut self, request: impl IntoRequest<InstanceStateLookupRequest>, ) -> Result<Response<InstanceStateValueAtKey>, Status>

Get the value at a specific key of a contract state. In contrast to GetInstanceState this is more efficient, but requires the user to know the specific key to look for.

Source

pub async fn get_next_account_sequence_number( &mut self, request: impl IntoRequest<AccountAddress>, ) -> Result<Response<NextAccountSequenceNumber>, Status>

Get the best guess as to what the next account sequence number should be. If all account transactions are finalized then this information is reliable. Otherwise this is the best guess, assuming all other transactions will be committed to blocks and eventually finalized.

Source

pub async fn get_consensus_info( &mut self, request: impl IntoRequest<Empty>, ) -> Result<Response<ConsensusInfo>, Status>

Get information about the current state of consensus.

Source

pub async fn get_block_item_status( &mut self, request: impl IntoRequest<TransactionHash>, ) -> Result<Response<BlockItemStatus>, Status>

Get the status of and information about a specific block item (transaction).

Source

pub async fn get_cryptographic_parameters( &mut self, request: impl IntoRequest<BlockHashInput>, ) -> Result<Response<CryptographicParameters>, Status>

Get the cryptographic parameters in a given block.

Source

pub async fn get_block_info( &mut self, request: impl IntoRequest<BlockHashInput>, ) -> Result<Response<BlockInfo>, Status>

Get information, such as height, timings, and transaction counts for the given block.

Source

pub async fn get_baker_list( &mut self, request: impl IntoRequest<BlockHashInput>, ) -> Result<Response<Streaming<BakerId>>, Status>

Get all the bakers at the end of the given block.

Source

pub async fn get_pool_info( &mut self, request: impl IntoRequest<PoolInfoRequest>, ) -> Result<Response<PoolInfoResponse>, Status>

Get information about a given pool at the end of a given block.

Source

pub async fn get_passive_delegation_info( &mut self, request: impl IntoRequest<BlockHashInput>, ) -> Result<Response<PassiveDelegationInfo>, Status>

Get information about the passive delegators at the end of a given block.

Source

pub async fn get_blocks_at_height( &mut self, request: impl IntoRequest<BlocksAtHeightRequest>, ) -> Result<Response<BlocksAtHeightResponse>, Status>

Get a list of live blocks at a given height.

Source

pub async fn get_tokenomics_info( &mut self, request: impl IntoRequest<BlockHashInput>, ) -> Result<Response<TokenomicsInfo>, Status>

Get information about tokenomics at the end of a given block.

Source

pub async fn invoke_instance( &mut self, request: impl IntoRequest<InvokeInstanceRequest>, ) -> Result<Response<InvokeInstanceResponse>, Status>

Run the smart contract entrypoint in a given context and in the state at the end of the given block.

Source

pub async fn get_pool_delegators( &mut self, request: impl IntoRequest<GetPoolDelegatorsRequest>, ) -> Result<Response<Streaming<DelegatorInfo>>, Status>

Get the registered delegators of a given pool at the end of a given block. In contrast to the GetPoolDelegatorsRewardPeriod which returns delegators that are fixed for the reward period of the block, this endpoint returns the list of delegators that are registered in the block. Any changes to delegators are immediately visible in this list. The stream will end when all the delegators has been returned.

Source

pub async fn get_pool_delegators_reward_period( &mut self, request: impl IntoRequest<GetPoolDelegatorsRequest>, ) -> Result<Response<Streaming<DelegatorRewardPeriodInfo>>, Status>

Get the fixed delegators of a given pool for the reward period of the given block. In contracts to the GetPoolDelegators which returns delegators registered for the given block, this endpoint returns the fixed delegators contributing stake in the reward period containing the given block. The stream will end when all the delegators has been returned.

Source

pub async fn get_passive_delegators( &mut self, request: impl IntoRequest<BlockHashInput>, ) -> Result<Response<Streaming<DelegatorInfo>>, Status>

Get the registered passive delegators at the end of a given block. In contrast to the GetPassiveDelegatorsRewardPeriod which returns delegators that are fixed for the reward period of the block, this endpoint returns the list of delegators that are registered in the block. Any changes to delegators are immediately visible in this list. The stream will end when all the delegators has been returned.

Source

pub async fn get_passive_delegators_reward_period( &mut self, request: impl IntoRequest<BlockHashInput>, ) -> Result<Response<Streaming<DelegatorRewardPeriodInfo>>, Status>

Get the fixed passive delegators for the reward period of the given block. In contracts to the GetPassiveDelegators which returns delegators registered for the given block, this endpoint returns the fixed delegators contributing stake in the reward period containing the given block. The stream will end when all the delegators has been returned.

Source

pub async fn get_branches( &mut self, request: impl IntoRequest<Empty>, ) -> Result<Response<Branch>, Status>

Get the current branches of blocks starting from and including the last finalized block.

Source

pub async fn get_election_info( &mut self, request: impl IntoRequest<BlockHashInput>, ) -> Result<Response<ElectionInfo>, Status>

Get information related to the baker election for a particular block.

Source

pub async fn get_identity_providers( &mut self, request: impl IntoRequest<BlockHashInput>, ) -> Result<Response<Streaming<IpInfo>>, Status>

Get the identity providers registered as of the end of a given block. The stream will end when all the identity providers have been returned.

Source

pub async fn get_anonymity_revokers( &mut self, request: impl IntoRequest<BlockHashInput>, ) -> Result<Response<Streaming<ArInfo>>, Status>

Get the anonymity revokers registered as of the end of a given block. The stream will end when all the anonymity revokers have been returned.

Source

pub async fn get_account_non_finalized_transactions( &mut self, request: impl IntoRequest<AccountAddress>, ) -> Result<Response<Streaming<TransactionHash>>, Status>

Get a list of non-finalized transaction hashes for a given account. This endpoint is not expected to return a large amount of data in most cases, but in bad network condtions it might. The stream will end when all the non-finalized transaction hashes have been returned.

Source

pub async fn get_block_transaction_events( &mut self, request: impl IntoRequest<BlockHashInput>, ) -> Result<Response<Streaming<BlockItemSummary>>, Status>

Get a list of transaction events in a given block. The stream will end when all the transaction events for a given block have been returned.

Source

pub async fn get_block_special_events( &mut self, request: impl IntoRequest<BlockHashInput>, ) -> Result<Response<Streaming<BlockSpecialEvent>>, Status>

Get a list of special events in a given block. These are events generated by the protocol, such as minting and reward payouts. They are not directly generated by any transaction. The stream will end when all the special events for a given block have been returned.

Source

pub async fn get_block_pending_updates( &mut self, request: impl IntoRequest<BlockHashInput>, ) -> Result<Response<Streaming<PendingUpdate>>, Status>

Get the pending updates to chain parameters at the end of a given block. The stream will end when all the pending updates for a given block have been returned.

Source

pub async fn get_next_update_sequence_numbers( &mut self, request: impl IntoRequest<BlockHashInput>, ) -> Result<Response<NextUpdateSequenceNumbers>, Status>

Get next available sequence numbers for updating chain parameters after a given block.

Source

pub async fn get_scheduled_release_accounts( &mut self, request: impl IntoRequest<BlockHashInput>, ) -> Result<Response<Streaming<AccountPending>>, Status>

Get all accounts that have scheduled releases, with the timestamp of the first pending scheduled release for that account. (Note, this only identifies accounts by index, and only indicates the first pending release for each account.)

Source

pub async fn get_cooldown_accounts( &mut self, request: impl IntoRequest<BlockHashInput>, ) -> Result<Response<Streaming<AccountPending>>, Status>

Get all accounts that have stake in cooldown, with the timestamp of the first pending cooldown expiry for each account. (Note, this only identifies accounts by index, and only indicates the first pending cooldown for each account.) Prior to protocol version 7, the resulting stream will always be empty.

Source

pub async fn get_pre_cooldown_accounts( &mut self, request: impl IntoRequest<BlockHashInput>, ) -> Result<Response<Streaming<AccountIndex>>, Status>

Get all accounts that have stake in pre-cooldown. (This only identifies accounts by index.) Prior to protocol version 7, the resulting stream will always be empty.

Source

pub async fn get_pre_pre_cooldown_accounts( &mut self, request: impl IntoRequest<BlockHashInput>, ) -> Result<Response<Streaming<AccountIndex>>, Status>

Get all accounts that have stake in pre-pre-cooldown. (This only identifies accounts by index.) Prior to protocol version 7, the resulting stream will always be empty.

Source

pub async fn get_baker_earliest_win_time( &mut self, request: impl IntoRequest<BakerId>, ) -> Result<Response<Timestamp>, Status>

Get the projected earliest time at which a particular baker will be required to bake a block. If the current consensus version is 0, this returns the status ‘Unavailable’, as the endpoint is only supported by consensus version 1.

If the baker is not a baker for the current reward period, this returns a timestamp at the start of the next reward period. If the baker is a baker for the current reward period, the earliest win time is projected from the current round forward, assuming that each round after the last finalized round will take the minimum block time. (If blocks take longer, or timeouts occur, the actual time may be later, and the reported time in subsequent queries may reflect this.) At the end of an epoch (or if the baker is not projected to bake before the end of the epoch) the earliest win time for a (current) baker will be projected as the start of the next epoch. This is because the seed for the leader election is updated at the epoch boundary, and so the winners cannot be predicted beyond that. Note that in some circumstances the returned timestamp can be in the past, especially at the end of an epoch.

Source

pub async fn shutdown( &mut self, request: impl IntoRequest<Empty>, ) -> Result<Response<Empty>, Status>

Shut down the node. Return a GRPC error if the shutdown failed.

Source

pub async fn peer_connect( &mut self, request: impl IntoRequest<IpSocketAddress>, ) -> Result<Response<Empty>, Status>

Suggest to a peer to connect to the submitted peer details. This, if successful, adds the peer to the list of given addresses. Otherwise return a GRPC error. Note. The peer might not be connected to instantly, in that case the node will try to establish the connection in near future. This function returns a GRPC status ‘Ok’ in this case.

Source

pub async fn peer_disconnect( &mut self, request: impl IntoRequest<IpSocketAddress>, ) -> Result<Response<Empty>, Status>

Disconnect from the peer and remove them from the given addresses list if they are on it. Return if the request was processed successfully. Otherwise return a GRPC error.

Source

pub async fn get_banned_peers( &mut self, request: impl IntoRequest<Empty>, ) -> Result<Response<BannedPeers>, Status>

Get a list of banned peers.

Source

pub async fn ban_peer( &mut self, request: impl IntoRequest<PeerToBan>, ) -> Result<Response<Empty>, Status>

Ban the given peer. Returns a GRPC error if the action failed.

Source

pub async fn unban_peer( &mut self, request: impl IntoRequest<BannedPeer>, ) -> Result<Response<Empty>, Status>

Unban the banned peer. Returns a GRPC error if the action failed.

Source

pub async fn dump_start( &mut self, request: impl IntoRequest<DumpRequest>, ) -> Result<Response<Empty>, Status>

Start dumping packages into the specified file. Only enabled if the node was built with the network_dump feature. Returns a GRPC error if the network dump failed to start.

Source

pub async fn dump_stop( &mut self, request: impl IntoRequest<Empty>, ) -> Result<Response<Empty>, Status>

Stop dumping packages. Only enabled if the node was built with the network_dump feature. Returns a GRPC error if the network dump failed to be stopped.

Source

pub async fn get_peers_info( &mut self, request: impl IntoRequest<Empty>, ) -> Result<Response<PeersInfo>, Status>

Get a list of the peers that the node is connected to and assoicated network related information for each peer.

Source

pub async fn get_node_info( &mut self, request: impl IntoRequest<Empty>, ) -> Result<Response<NodeInfo>, Status>

Get information about the node. The NodeInfo includes information of

  • Meta information such as the, version of the node, type of the node, uptime and the local time of the node.
  • NetworkInfo which yields data such as the node id, packets sent/received, average bytes per second sent/received.
  • ConsensusInfo. The ConsensusInfo returned depends on if the node supports the protocol on chain and whether the node is configured as a baker or not.
Source

pub async fn send_block_item( &mut self, request: impl IntoRequest<SendBlockItemRequest>, ) -> Result<Response<TransactionHash>, Status>

Send a block item. A block item is either an AccountTransaction, which is a transaction signed and paid for by an account, a CredentialDeployment, which creates a new account, or UpdateInstruction, which is an instruction to change some parameters of the chain. Update instructions can only be sent by the governance committee.

Returns a hash of the block item, which can be used with GetBlockItemStatus.

Source

pub async fn get_account_transaction_sign_hash( &mut self, request: impl IntoRequest<PreAccountTransaction>, ) -> Result<Response<AccountTransactionSignHash>, Status>

Get the hash to be signed for an account transaction. The hash returned should be signed and the signatures included as an AccountTransactionSignature when calling SendBlockItem. This is provided as a convenience to support cases where the right SDK is not available for interacting with the node. If an SDK is available then it is strongly recommended to compute this hash off-line using it. That reduces the trust in the node, removes networking failure modes, and will perform better.

Source

pub async fn get_block_chain_parameters( &mut self, request: impl IntoRequest<BlockHashInput>, ) -> Result<Response<ChainParameters>, Status>

Get the values of chain parameters in effect in the given block.

Source

pub async fn get_block_finalization_summary( &mut self, request: impl IntoRequest<BlockHashInput>, ) -> Result<Response<BlockFinalizationSummary>, Status>

Get the summary of the finalization data in a given block.

Source

pub async fn get_block_items( &mut self, request: impl IntoRequest<BlockHashInput>, ) -> Result<Response<Streaming<BlockItem>>, Status>

Get the items of a block.

Source

pub async fn get_bakers_reward_period( &mut self, request: impl IntoRequest<BlockHashInput>, ) -> Result<Response<Streaming<BakerRewardPeriodInfo>>, Status>

Get all bakers in the reward period of a block. This endpoint is only supported for protocol version 6 and onwards. If the protocol does not support the endpoint then an ‘IllegalArgument’ error is returned.

Source

pub async fn get_block_certificates( &mut self, request: impl IntoRequest<BlockHashInput>, ) -> Result<Response<BlockCertificates>, Status>

For a non-genesis block, this returns the quorum certificate, a timeout certificate (if present) and epoch finalization entry (if present). Note that, if the block being pointed to is not a product of ConcordiumBFT, then the response will be a grpc error (invalid argument). If the endpoint is not enabled by the node, then an ‘unimplemented’ error will be returned.

Source

pub async fn get_winning_bakers_epoch( &mut self, request: impl IntoRequest<EpochRequest>, ) -> Result<Response<Streaming<WinningBaker>>, Status>

Get the list of bakers that won the lottery in a particular historical epoch (i.e. the last finalized block is in a later epoch). This lists the winners for each round in the epoch, starting from the round after the last block in the previous epoch, running to the round before the first block in the next epoch. It also indicates if a block in each round was included in the finalized chain.

The following error cases are possible:

  • NOT_FOUND if the query specifies an unknown block.
  • UNAVAILABLE if the query is for an epoch that is not finalized in the current genesis index, or is for a future genesis index.
  • INVALID_ARGUMENT if the query is for an epoch that is not finalized for a past genesis index.
  • INVALID_ARGUMENT if the query is for a genesis index at consensus version 0.
  • INVALID_ARGUMENT if the input EpochRequest is malformed.
  • UNIMPLEMENTED if the endpoint is disabled on the node.
Source

pub async fn get_first_block_epoch( &mut self, request: impl IntoRequest<EpochRequest>, ) -> Result<Response<BlockHash>, Status>

Get the block hash of the first finalized block in a specified epoch.

The following error cases are possible:

  • NOT_FOUND if the query specifies an unknown block.
  • UNAVAILABLE if the query is for an epoch that is not finalized in the current genesis index, or is for a future genesis index.
  • INVALID_ARGUMENT if the query is for an epoch with no finalized blocks for a past genesis index.
  • INVALID_ARGUMENT if the input EpochRequest is malformed.
  • UNIMPLEMENTED if the endpoint is disabled on the node.
Source

pub async fn get_consensus_detailed_status( &mut self, request: impl IntoRequest<ConsensusDetailedStatusQuery>, ) -> Result<Response<ConsensusDetailedStatus>, Status>

Get the detailed status of the consensus. This is only available for consensus version 1.

The following error cases are possible:

  • NOT_FOUND if the query specifies an unknown genesis index.
  • INVALID_ARGUMENT if the query specifies a genesis index at consensus version 0.
  • UNIMPLEMENTED if the endpoint is disabled on the node.
Source

pub async fn dry_run( &mut self, request: impl IntoStreamingRequest<Message = DryRunRequest>, ) -> Result<Response<Streaming<DryRunResponse>>, Status>

Dry run a series of transactions and operations on a state derived from a specified block. The server should send a single DryRunResponse for each DryRunRequest received, unless the call fails with an error status code. If a request produces a DryRunErrorResponse, then the server will still process subsequent requests, just as if the request causing the error did not happen.

The first request should be load_block_at_state to determine the block state that will be used for the dry run.

The server associates each request with an energy cost, and limits the total energy that may be expended in a single invocation of DryRun. This limit is reported as quota in the initial metadata returned by the server. If executing an operation exceeds the limit, the server terminates the session with RESOURCE_EXHAUSTED.

The server also imposes a timeout for a dry-run session to complete. The server reports the timeout duration in milliseconds in the initial metadata field timeout. If the session is not completed before the timeout elapses, the server terminates the session with DEADLINE_EXCEEDED.

The following error cases are possible:

  • INVALID_ARGUMENT if any DryRunRequest is malformed.
  • RESOURCE_EXHAUSTED if the energy quota is exceeded.
  • DEADLINE_EXCEEDED if the session does not complete before the server-imposed timeout.
  • RESOURCE_EXHAUSTED if the server is not currently accepting new DryRun sessions. (The server may impose a limit on the number of concurrent sessions.)
  • INTERNAL if an interal server error occurs. This should not happen, and likely indicates a bug.
  • UNIMPLEMENTED if the endpoint is disabled on the node.

Trait Implementations§

Source§

impl<T: Clone> Clone for QueriesClient<T>

Source§

fn clone(&self) -> QueriesClient<T>

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl<T: Debug> Debug for QueriesClient<T>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

§

impl<T> !Freeze for QueriesClient<T>

§

impl<T> RefUnwindSafe for QueriesClient<T>
where T: RefUnwindSafe,

§

impl<T> Send for QueriesClient<T>
where T: Send,

§

impl<T> Sync for QueriesClient<T>
where T: Sync,

§

impl<T> Unpin for QueriesClient<T>
where T: Unpin,

§

impl<T> UnwindSafe for QueriesClient<T>
where T: UnwindSafe,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> Conv for T

Source§

fn conv<T>(self) -> T
where Self: Into<T>,

Converts self into T using Into<T>. Read more
Source§

impl<T> FmtForward for T

Source§

fn fmt_binary(self) -> FmtBinary<Self>
where Self: Binary,

Causes self to use its Binary implementation when Debug-formatted.
Source§

fn fmt_display(self) -> FmtDisplay<Self>
where Self: Display,

Causes self to use its Display implementation when Debug-formatted.
Source§

fn fmt_lower_exp(self) -> FmtLowerExp<Self>
where Self: LowerExp,

Causes self to use its LowerExp implementation when Debug-formatted.
Source§

fn fmt_lower_hex(self) -> FmtLowerHex<Self>
where Self: LowerHex,

Causes self to use its LowerHex implementation when Debug-formatted.
Source§

fn fmt_octal(self) -> FmtOctal<Self>
where Self: Octal,

Causes self to use its Octal implementation when Debug-formatted.
Source§

fn fmt_pointer(self) -> FmtPointer<Self>
where Self: Pointer,

Causes self to use its Pointer implementation when Debug-formatted.
Source§

fn fmt_upper_exp(self) -> FmtUpperExp<Self>
where Self: UpperExp,

Causes self to use its UpperExp implementation when Debug-formatted.
Source§

fn fmt_upper_hex(self) -> FmtUpperHex<Self>
where Self: UpperHex,

Causes self to use its UpperHex implementation when Debug-formatted.
Source§

fn fmt_list(self) -> FmtList<Self>
where &'a Self: for<'a> IntoIterator,

Formats each item in a sequence. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> FromRef<T> for T
where T: Clone,

Source§

fn from_ref(input: &T) -> T

Converts to this type from a reference to the input type.
Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts 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 more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts 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
Source§

impl<T> IntoRequest<T> for T

Source§

fn into_request(self) -> Request<T>

Wrap the input message T in a tonic::Request
Source§

impl<T> Pipe for T
where T: ?Sized,

Source§

fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> R
where Self: Sized,

Pipes by value. This is generally the method you want to use. Read more
Source§

fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> R
where R: 'a,

Borrows self and passes that borrow into the pipe function. Read more
Source§

fn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> R
where R: 'a,

Mutably borrows self and passes that borrow into the pipe function. Read more
Source§

fn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> R
where Self: Borrow<B>, B: 'a + ?Sized, R: 'a,

Borrows self, then passes self.borrow() into the pipe function. Read more
Source§

fn pipe_borrow_mut<'a, B, R>( &'a mut self, func: impl FnOnce(&'a mut B) -> R, ) -> R
where Self: BorrowMut<B>, B: 'a + ?Sized, R: 'a,

Mutably borrows self, then passes self.borrow_mut() into the pipe function. Read more
Source§

fn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> R
where Self: AsRef<U>, U: 'a + ?Sized, R: 'a,

Borrows self, then passes self.as_ref() into the pipe function.
Source§

fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> R
where Self: AsMut<U>, U: 'a + ?Sized, R: 'a,

Mutably borrows self, then passes self.as_mut() into the pipe function.
Source§

fn pipe_deref<'a, T, R>(&'a self, func: impl FnOnce(&'a T) -> R) -> R
where Self: Deref<Target = T>, T: 'a + ?Sized, R: 'a,

Borrows self, then passes self.deref() into the pipe function.
Source§

fn pipe_deref_mut<'a, T, R>( &'a mut self, func: impl FnOnce(&'a mut T) -> R, ) -> R
where Self: DerefMut<Target = T> + Deref, T: 'a + ?Sized, R: 'a,

Mutably borrows self, then passes self.deref_mut() into the pipe function.
Source§

impl<T> Pointable for T

Source§

const ALIGN: usize

The alignment of pointer.
Source§

type Init = T

The type for initializers.
Source§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
Source§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
Source§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
Source§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> Tap for T

Source§

fn tap(self, func: impl FnOnce(&Self)) -> Self

Immutable access to a value. Read more
Source§

fn tap_mut(self, func: impl FnOnce(&mut Self)) -> Self

Mutable access to a value. Read more
Source§

fn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
where Self: Borrow<B>, B: ?Sized,

Immutable access to the Borrow<B> of a value. Read more
Source§

fn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
where Self: BorrowMut<B>, B: ?Sized,

Mutable access to the BorrowMut<B> of a value. Read more
Source§

fn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
where Self: AsRef<R>, R: ?Sized,

Immutable access to the AsRef<R> view of a value. Read more
Source§

fn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
where Self: AsMut<R>, R: ?Sized,

Mutable access to the AsMut<R> view of a value. Read more
Source§

fn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
where Self: Deref<Target = T>, T: ?Sized,

Immutable access to the Deref::Target of a value. Read more
Source§

fn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
where Self: DerefMut<Target = T> + Deref, T: ?Sized,

Mutable access to the Deref::Target of a value. Read more
Source§

fn tap_dbg(self, func: impl FnOnce(&Self)) -> Self

Calls .tap() only in debug builds, and is erased in release builds.
Source§

fn tap_mut_dbg(self, func: impl FnOnce(&mut Self)) -> Self

Calls .tap_mut() only in debug builds, and is erased in release builds.
Source§

fn tap_borrow_dbg<B>(self, func: impl FnOnce(&B)) -> Self
where Self: Borrow<B>, B: ?Sized,

Calls .tap_borrow() only in debug builds, and is erased in release builds.
Source§

fn tap_borrow_mut_dbg<B>(self, func: impl FnOnce(&mut B)) -> Self
where Self: BorrowMut<B>, B: ?Sized,

Calls .tap_borrow_mut() only in debug builds, and is erased in release builds.
Source§

fn tap_ref_dbg<R>(self, func: impl FnOnce(&R)) -> Self
where Self: AsRef<R>, R: ?Sized,

Calls .tap_ref() only in debug builds, and is erased in release builds.
Source§

fn tap_ref_mut_dbg<R>(self, func: impl FnOnce(&mut R)) -> Self
where Self: AsMut<R>, R: ?Sized,

Calls .tap_ref_mut() only in debug builds, and is erased in release builds.
Source§

fn tap_deref_dbg<T>(self, func: impl FnOnce(&T)) -> Self
where Self: Deref<Target = T>, T: ?Sized,

Calls .tap_deref() only in debug builds, and is erased in release builds.
Source§

fn tap_deref_mut_dbg<T>(self, func: impl FnOnce(&mut T)) -> Self
where Self: DerefMut<Target = T> + Deref, T: ?Sized,

Calls .tap_deref_mut() only in debug builds, and is erased in release builds.
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T> TryConv for T

Source§

fn try_conv<T>(self) -> Result<T, Self::Error>
where Self: TryInto<T>,

Attempts to convert self into T using TryInto<T>. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V

Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more