pub struct DefaultMQProducer { /* private fields */ }Implementations§
Source§impl DefaultMQProducer
impl DefaultMQProducer
pub fn builder(client_runtime: Arc<ClientRuntime>) -> DefaultMQProducerBuilder
pub fn new(client_runtime: Arc<ClientRuntime>) -> Self
Sourcepub fn client_session(&self) -> Option<&ClientSession>
pub fn client_session(&self) -> Option<&ClientSession>
Returns the shared session for a producer created through the public builder. Internal bootstrap producers intentionally have no public session.
pub async fn start(&mut self) -> ClientResult<()>
pub async fn shutdown(&mut self)
pub async fn fetch_publish_message_queues( &mut self, topic: &str, ) -> ClientResult<Vec<MessageQueue>>
pub async fn create_topic( &mut self, key: &str, new_topic: &str, queue_num: i32, attributes: HashMap<String, String>, ) -> ClientResult<()>
pub async fn create_topic_with_flag( &mut self, key: &str, new_topic: &str, queue_num: i32, topic_sys_flag: i32, attributes: HashMap<String, String>, ) -> ClientResult<()>
pub async fn search_offset( &mut self, mq: &MessageQueue, timestamp: u64, ) -> ClientResult<i64>
pub async fn max_offset(&mut self, mq: &MessageQueue) -> ClientResult<i64>
pub async fn min_offset(&mut self, mq: &MessageQueue) -> ClientResult<i64>
pub async fn earliest_msg_store_time( &mut self, mq: &MessageQueue, ) -> ClientResult<i64>
pub async fn query_message( &mut self, topic: &str, key: &str, max_num: i32, begin: u64, end: u64, ) -> ClientResult<QueryResult>
pub async fn view_message( &mut self, topic: &str, msg_id: &str, ) -> ClientResult<MessageExt>
pub async fn send<M>(&self, msg: M) -> ClientResult<Option<SendResult>>
pub async fn send_with_timeout<M>( &self, msg: M, timeout: u64, ) -> ClientResult<Option<SendResult>>
pub async fn send_with_callback<M, F>(
&self,
msg: M,
send_callback: F,
) -> ClientResult<()>where
M: MessageTrait + Send + Sync,
F: Fn(Option<&SendResult>, Option<&ClientError>) + Send + Sync + 'static,
pub async fn send_with_callback_timeout<F, M>(
&self,
msg: M,
send_callback: F,
timeout: u64,
) -> ClientResult<()>where
F: Fn(Option<&SendResult>, Option<&ClientError>) + Send + Sync + 'static,
M: MessageTrait + Send + Sync,
pub async fn send_oneway<M>(&self, msg: M) -> ClientResult<()>
pub async fn send_to_queue<M>( &self, msg: M, mq: MessageQueue, ) -> ClientResult<Option<SendResult>>
pub async fn send_to_queue_with_timeout<M>( &self, msg: M, mq: MessageQueue, timeout: u64, ) -> ClientResult<Option<SendResult>>
pub async fn send_to_queue_with_callback<M, F>(
&self,
msg: M,
mq: MessageQueue,
send_callback: F,
) -> ClientResult<()>where
M: MessageTrait + Send + Sync,
F: Fn(Option<&SendResult>, Option<&ClientError>) + Send + Sync + 'static,
pub async fn send_to_queue_with_callback_timeout<M, F>(
&self,
msg: M,
mq: MessageQueue,
send_callback: F,
timeout: u64,
) -> ClientResult<()>where
M: MessageTrait + Send + Sync,
F: Fn(Option<&SendResult>, Option<&ClientError>) + Send + Sync + 'static,
pub async fn send_oneway_to_queue<M>( &self, msg: M, mq: MessageQueue, ) -> ClientResult<()>
pub async fn send_with_selector<M, S, T>(
&self,
msg: M,
selector: S,
arg: T,
) -> ClientResult<Option<SendResult>>where
M: MessageTrait + Send + Sync,
S: Fn(&[MessageQueue], &M, &T) -> Option<MessageQueue> + Send + Sync,
T: Send + Sync,
pub async fn send_with_selector_timeout<M, S, T>(
&self,
msg: M,
selector: S,
arg: T,
timeout: u64,
) -> ClientResult<Option<SendResult>>where
M: MessageTrait + Send + Sync,
S: Fn(&[MessageQueue], &M, &T) -> Option<MessageQueue> + Send + Sync,
T: Send + Sync,
pub async fn send_with_selector_callback<M, S, T>(
&self,
msg: M,
selector: S,
arg: T,
send_callback: Option<ArcSendCallback>,
) -> ClientResult<()>where
M: MessageTrait + Send + Sync,
S: Fn(&[MessageQueue], &M, &T) -> Option<MessageQueue> + Send + Sync,
T: Send + Sync,
pub async fn send_with_selector_callback_timeout<M, S, T>(
&self,
msg: M,
selector: S,
arg: T,
send_callback: Option<ArcSendCallback>,
timeout: u64,
) -> ClientResult<()>where
M: MessageTrait + Send + Sync,
S: Fn(&[MessageQueue], &M, &T) -> Option<MessageQueue> + Send + Sync + 'static,
T: Send + Sync + 'static,
pub async fn send_oneway_with_selector<M, S, T>(
&self,
msg: M,
selector: S,
arg: T,
) -> ClientResult<()>where
M: MessageTrait + Send + Sync,
S: Fn(&[MessageQueue], &M, &T) -> Option<MessageQueue> + Send + Sync + 'static,
T: Send + Sync + 'static,
pub async fn send_message_in_transaction<T, M>( &self, msg: M, arg: Option<T>, ) -> ClientResult<TransactionSendResult>
pub async fn send_batch<M>(&self, msgs: Vec<M>) -> ClientResult<SendResult>
pub async fn send_batch_with_timeout<M>( &self, msgs: Vec<M>, timeout: u64, ) -> ClientResult<SendResult>
pub async fn send_batch_to_queue<M>( &self, msgs: Vec<M>, mq: MessageQueue, ) -> ClientResult<SendResult>
pub async fn send_batch_to_queue_with_timeout<M>( &self, msgs: Vec<M>, mq: MessageQueue, timeout: u64, ) -> ClientResult<SendResult>
pub async fn send_batch_with_callback<M, F>(
&self,
msgs: Vec<M>,
f: F,
) -> ClientResult<()>where
M: MessageTrait + Send + Sync,
F: Fn(Option<&SendResult>, Option<&ClientError>) + Send + Sync + 'static,
pub async fn send_batch_with_callback_timeout<M, F>(
&self,
msgs: Vec<M>,
f: F,
timeout: u64,
) -> ClientResult<()>where
M: MessageTrait + Send + Sync,
F: Fn(Option<&SendResult>, Option<&ClientError>) + Send + Sync + 'static,
pub async fn send_batch_to_queue_with_callback<M, F>(
&self,
msgs: Vec<M>,
mq: MessageQueue,
f: F,
) -> ClientResult<()>where
M: MessageTrait + Send + Sync,
F: Fn(Option<&SendResult>, Option<&ClientError>) + Send + Sync + 'static,
pub async fn send_batch_to_queue_with_callback_timeout<M, F>(
&self,
msgs: Vec<M>,
mq: MessageQueue,
f: F,
timeout: u64,
) -> ClientResult<()>where
M: MessageTrait + Send + Sync,
F: Fn(Option<&SendResult>, Option<&ClientError>) + Send + Sync + 'static,
pub async fn request<M>( &self, msg: M, timeout: u64, ) -> ClientResult<Box<dyn MessageTrait + Send>>
pub async fn request_with_callback<F, M>(
&self,
msg: M,
request_callback: F,
timeout: u64,
) -> ClientResult<()>where
F: Fn(Option<&dyn MessageTrait>, Option<&ClientError>) + Send + Sync + 'static,
M: MessageTrait + Send + Sync,
pub async fn request_with_selector<M, S, T>(
&self,
msg: M,
selector: S,
arg: T,
timeout: u64,
) -> ClientResult<Box<dyn MessageTrait + Send>>where
S: Fn(&[MessageQueue], &M, &T) -> Option<MessageQueue> + Send + Sync + 'static,
T: Send + Sync + 'static,
M: MessageTrait + Send + Sync,
pub async fn request_with_selector_callback<M, S, T, F>(
&self,
msg: M,
selector: S,
arg: T,
request_callback: F,
timeout: u64,
) -> ClientResult<()>where
S: Fn(&[MessageQueue], &M, &T) -> Option<MessageQueue> + Send + Sync + 'static,
F: Fn(Option<&dyn MessageTrait>, Option<&ClientError>) + Send + Sync + 'static,
T: Send + Sync + 'static,
M: MessageTrait + Send + Sync,
pub async fn request_to_queue<M>( &self, msg: M, mq: MessageQueue, timeout: u64, ) -> ClientResult<Box<dyn MessageTrait + Send>>
pub async fn request_to_queue_with_callback<M, F>(
&self,
msg: M,
mq: MessageQueue,
request_callback: F,
timeout: u64,
) -> ClientResult<()>where
F: Fn(Option<&dyn MessageTrait>, Option<&ClientError>) + Send + Sync + 'static,
M: MessageTrait + Send + Sync,
pub async fn recall_message( &self, topic: impl Into<CheetahString>, recall_handle: impl Into<CheetahString>, ) -> ClientResult<String>
pub fn client_config_snapshot(&self) -> Arc<ClientConfig> ⓘ
pub fn default_mq_producer_impl(&self) -> Option<&Arc<DefaultMQProducerImpl>>
pub fn get_default_mq_producer_impl( &self, ) -> Option<&Arc<DefaultMQProducerImpl>>
pub fn retry_response_codes(&self) -> HashSet<i32>
pub fn get_retry_response_codes(&self) -> HashSet<i32>
pub fn producer_group(&self) -> CheetahString
pub fn get_producer_group(&self) -> CheetahString
pub fn topics(&self) -> Vec<CheetahString>
pub fn get_topics(&self) -> Vec<CheetahString>
pub fn create_topic_key(&self) -> CheetahString
pub fn get_create_topic_key(&self) -> CheetahString
pub fn default_topic_queue_nums(&self) -> u32
pub fn get_default_topic_queue_nums(&self) -> u32
pub fn send_msg_timeout(&self) -> u32
pub fn get_send_msg_timeout(&self) -> u32
pub fn compress_msg_body_over_howmuch(&self) -> u32
pub fn get_compress_msg_body_over_howmuch(&self) -> u32
pub fn retry_times_when_send_failed(&self) -> u32
pub fn get_retry_times_when_send_failed(&self) -> u32
pub fn retry_times_when_send_async_failed(&self) -> u32
pub fn get_retry_times_when_send_async_failed(&self) -> u32
pub fn retry_another_broker_when_not_store_ok(&self) -> bool
pub fn is_retry_another_broker_when_not_store_ok(&self) -> bool
pub fn is_send_message_with_vip_channel(&self) -> bool
pub fn is_send_message_with_vipchannel(&self) -> bool
pub fn max_message_size(&self) -> u32
pub fn get_max_message_size(&self) -> u32
pub fn trace_dispatcher(&self) -> Option<ArcTraceDispatcher>
pub fn get_trace_dispatcher(&self) -> Option<ArcTraceDispatcher>
pub fn auto_batch(&self) -> bool
pub fn produce_accumulator(&self) -> Option<Arc<ProduceAccumulator>>
pub fn enable_backpressure_for_async_mode(&self) -> bool
pub fn is_enable_backpressure_for_async_mode(&self) -> bool
pub fn back_pressure_for_async_send_num(&self) -> u32
pub fn get_back_pressure_for_async_send_num(&self) -> u32
pub fn back_pressure_for_async_send_size(&self) -> u32
pub fn get_back_pressure_for_async_send_size(&self) -> u32
pub fn send_msg_max_timeout_per_request(&self) -> Option<u32>
pub fn get_send_msg_max_timeout_per_request(&self) -> Option<u32>
pub fn batch_max_delay_ms(&self) -> Option<u32>
pub fn get_batch_max_delay_ms(&self) -> Option<u32>
pub fn batch_max_bytes(&self) -> Option<u64>
pub fn get_batch_max_bytes(&self) -> Option<u64>
pub fn total_batch_max_bytes(&self) -> Option<u64>
pub fn get_total_batch_max_bytes(&self) -> Option<u64>
pub fn rpc_hook(&self) -> Option<Arc<dyn RPCHook>>
pub fn compress_level(&self) -> i32
pub fn get_compress_level(&self) -> i32
pub fn compress_type(&self) -> CompressionType
pub fn get_compress_type(&self) -> CompressionType
pub fn compressor(&self) -> Option<&'static (dyn Compressor + Send + Sync)>
pub fn get_compressor(&self) -> Option<&'static (dyn Compressor + Send + Sync)>
pub fn is_use_tls(&self) -> bool
pub fn set_use_tls(&mut self, use_tls: bool)
pub fn set_client_config(&mut self, client_config: ClientConfig)
pub fn set_retry_response_codes(&mut self, retry_response_codes: HashSet<i32>)
pub fn add_retry_response_code(&mut self, response_code: i32)
pub fn set_producer_group(&mut self, producer_group: impl Into<CheetahString>)
pub fn set_topics(&mut self, topics: Vec<CheetahString>)
pub fn set_create_topic_key( &mut self, create_topic_key: impl Into<CheetahString>, )
pub fn set_default_topic_queue_nums(&mut self, default_topic_queue_nums: u32)
pub fn set_send_msg_timeout(&mut self, send_msg_timeout: u32)
pub fn set_compress_msg_body_over_howmuch( &mut self, compress_msg_body_over_howmuch: u32, )
pub fn set_retry_times_when_send_failed( &mut self, retry_times_when_send_failed: u32, )
pub fn set_retry_times_when_send_async_failed( &mut self, retry_times_when_send_async_failed: u32, )
pub fn set_retry_another_broker_when_not_store_ok( &mut self, retry_another_broker_when_not_store_ok: bool, )
pub fn set_send_message_with_vip_channel( &mut self, send_message_with_vip_channel: bool, )
pub fn set_send_message_with_vipchannel( &mut self, send_message_with_vip_channel: bool, )
pub fn set_max_message_size(&mut self, max_message_size: u32)
pub fn set_trace_dispatcher(&mut self, trace_dispatcher: ArcTraceDispatcher)
pub fn set_auto_batch(&mut self, auto_batch: bool)
pub fn set_produce_accumulator( &mut self, produce_accumulator: ProduceAccumulator, )
pub fn set_enable_backpressure_for_async_mode( &mut self, enable_backpressure_for_async_mode: bool, )
pub fn set_back_pressure_for_async_send_num( &mut self, back_pressure_for_async_send_num: u32, )
pub fn set_back_pressure_for_async_send_size( &mut self, back_pressure_for_async_send_size: u32, )
pub fn set_rpc_hook(&mut self, rpc_hook: Arc<dyn RPCHook>)
pub fn set_compress_level(&mut self, compress_level: i32)
pub fn set_compress_type(&mut self, compress_type: CompressionType)
pub fn set_compressor( &mut self, compressor: Option<&'static (dyn Compressor + Send + Sync)>, )
pub fn set_send_msg_max_timeout_per_request(&mut self, timeout: u32)
pub fn set_send_msg_max_timeout_per_request_option( &mut self, timeout: Option<u32>, )
pub fn set_batch_max_delay_ms(&mut self, delay_ms: u32)
pub fn set_batch_max_delay_ms_option(&mut self, delay_ms: Option<u32>)
pub fn set_batch_max_bytes(&mut self, bytes: u64)
pub fn set_batch_max_bytes_option(&mut self, bytes: Option<u64>)
pub fn set_total_batch_max_bytes(&mut self, bytes: u64)
pub fn set_total_batch_max_bytes_option(&mut self, bytes: Option<u64>)
Sourcepub fn producer_config_snapshot(&self) -> Arc<ProducerConfig> ⓘ
pub fn producer_config_snapshot(&self) -> Arc<ProducerConfig> ⓘ
Returns the current immutable producer configuration snapshot.
pub fn set_send_latency_fault_enable(&mut self, send_latency_fault_enable: bool)
pub fn is_send_latency_fault_enable(&self) -> bool
pub fn set_start_detector_enable(&mut self, start_detector_enable: bool)
pub fn is_start_detector_enable(&self) -> bool
pub fn latency_max(&self) -> Vec<u64>
pub fn get_latency_max(&self) -> Vec<u64>
pub fn set_latency_max(&mut self, latency_max: impl Into<Vec<u64>>)
pub fn not_available_duration(&self) -> Vec<u64>
pub fn get_not_available_duration(&self) -> Vec<u64>
pub fn set_not_available_duration( &mut self, not_available_duration: impl Into<Vec<u64>>, )
pub fn init_produce_accumulator(&mut self)
pub fn set_back_pressure_for_async_send_num_inside_adjust( &mut self, back_pressure_for_async_send_num: u32, )
pub fn set_back_pressure_for_async_send_size_inside_adjust( &mut self, back_pressure_for_async_send_size: u32, )
pub fn get_auto_batch(&self) -> bool
pub async fn send_direct<M>( &self, msg: M, mq: Option<MessageQueue>, send_callback: Option<ArcSendCallback>, ) -> ClientResult<Option<SendResult>>
pub async fn send_by_accumulator<M>( &self, msg: M, mq: Option<MessageQueue>, send_callback: Option<ArcSendCallback>, ) -> ClientResult<Option<SendResult>>
Source§impl DefaultMQProducer
impl DefaultMQProducer
pub fn with_namespace( &self, resource: impl Into<CheetahString>, ) -> CheetahString
Trait Implementations§
Source§impl ClientSessionProvider for DefaultMQProducer
impl ClientSessionProvider for DefaultMQProducer
fn client_session(&self) -> Option<&ClientSession>
Source§impl Clone for DefaultMQProducer
impl Clone for DefaultMQProducer
Source§impl MessageQuery for DefaultMQProducer
impl MessageQuery for DefaultMQProducer
Source§async fn query(
&mut self,
request: ProducerQueryRequest,
) -> ClientResult<ProducerQueryResponse>
async fn query( &mut self, request: ProducerQueryRequest, ) -> ClientResult<ProducerQueryResponse>
Executes one producer query. Read more
Source§impl MessageRecall for DefaultMQProducer
impl MessageRecall for DefaultMQProducer
Source§async fn recall(&mut self, request: RecallRequest) -> ClientResult<String>
async fn recall(&mut self, request: RecallRequest) -> ClientResult<String>
Recalls one message. Read more
Source§impl MessageSend for DefaultMQProducer
impl MessageSend for DefaultMQProducer
Source§async fn send_message<M>(
&mut self,
request: SendRequest<M>,
) -> ClientResult<Option<SendResult>>
async fn send_message<M>( &mut self, request: SendRequest<M>, ) -> ClientResult<Option<SendResult>>
Sends one message using a closed request contract. Read more
Source§async fn send_message_batch<M>(
&mut self,
request: BatchSendRequest<M>,
) -> ClientResult<SendResult>
async fn send_message_batch<M>( &mut self, request: BatchSendRequest<M>, ) -> ClientResult<SendResult>
Sends a batch using a closed request contract. Read more
Source§async fn send_message_with_callback<M>(
&mut self,
request: SendCallbackRequest<M>,
) -> ClientResult<()>
async fn send_message_with_callback<M>( &mut self, request: SendCallbackRequest<M>, ) -> ClientResult<()>
Sends one message and reports completion through the supplied callback. Read more
Source§async fn send_selected<M, S, T>(
&mut self,
request: SelectedSendRequest<M, S, T>,
) -> ClientResult<Option<SendResult>>where
M: MessageTrait + Send + Sync,
S: Fn(&[MessageQueue], &M, &T) -> Option<MessageQueue> + Send + Sync + 'static,
T: Send + Sync + 'static,
async fn send_selected<M, S, T>(
&mut self,
request: SelectedSendRequest<M, S, T>,
) -> ClientResult<Option<SendResult>>where
M: MessageTrait + Send + Sync,
S: Fn(&[MessageQueue], &M, &T) -> Option<MessageQueue> + Send + Sync + 'static,
T: Send + Sync + 'static,
Sends one message using a queue selector. Read more
Source§async fn send_selected_with_callback<M, S, T>(
&mut self,
request: SelectedSendCallbackRequest<M, S, T>,
) -> ClientResult<()>where
M: MessageTrait + Send + Sync,
S: Fn(&[MessageQueue], &M, &T) -> Option<MessageQueue> + Send + Sync + 'static,
T: Send + Sync + 'static,
async fn send_selected_with_callback<M, S, T>(
&mut self,
request: SelectedSendCallbackRequest<M, S, T>,
) -> ClientResult<()>where
M: MessageTrait + Send + Sync,
S: Fn(&[MessageQueue], &M, &T) -> Option<MessageQueue> + Send + Sync + 'static,
T: Send + Sync + 'static,
Sends one selected message and reports completion through a callback. Read more
Source§async fn send_message_batch_with_callback<M>(
&mut self,
request: BatchSendCallbackRequest<M>,
) -> ClientResult<()>
async fn send_message_batch_with_callback<M>( &mut self, request: BatchSendCallbackRequest<M>, ) -> ClientResult<()>
Sends a batch and reports completion through a callback. Read more
Source§impl ProducerLifecycle for DefaultMQProducer
impl ProducerLifecycle for DefaultMQProducer
Source§async fn start_producer(&mut self) -> ClientResult<()>
async fn start_producer(&mut self) -> ClientResult<()>
Starts the producer. Read more
Source§async fn shutdown_producer(&mut self)
async fn shutdown_producer(&mut self)
Shuts down producer-owned work.
Source§impl ProducerTopicAdmin for DefaultMQProducer
impl ProducerTopicAdmin for DefaultMQProducer
Source§async fn create_topic_request(
&mut self,
request: TopicCreateRequest,
) -> ClientResult<()>
async fn create_topic_request( &mut self, request: TopicCreateRequest, ) -> ClientResult<()>
Creates a topic through the producer’s existing admin facade. Read more
Source§impl RequestReply for DefaultMQProducer
impl RequestReply for DefaultMQProducer
Source§async fn request_reply<M>(
&mut self,
request: RequestReplyRequest<M>,
) -> ClientResult<Box<dyn MessageTrait + Send>>
async fn request_reply<M>( &mut self, request: RequestReplyRequest<M>, ) -> ClientResult<Box<dyn MessageTrait + Send>>
Sends a request and waits for its correlated reply. Read more
Source§async fn request_reply_with_callback<M>(
&mut self,
request: RequestReplyCallbackRequest<M>,
) -> ClientResult<()>
async fn request_reply_with_callback<M>( &mut self, request: RequestReplyCallbackRequest<M>, ) -> ClientResult<()>
Sends a request and reports its correlated reply through a callback. Read more
Source§async fn request_reply_selected<M, S, T>(
&mut self,
request: SelectedRequestReplyRequest<M, S, T>,
) -> ClientResult<Box<dyn MessageTrait + Send>>where
M: MessageTrait + Send + Sync,
S: Fn(&[MessageQueue], &M, &T) -> Option<MessageQueue> + Send + Sync + 'static,
T: Send + Sync + 'static,
async fn request_reply_selected<M, S, T>(
&mut self,
request: SelectedRequestReplyRequest<M, S, T>,
) -> ClientResult<Box<dyn MessageTrait + Send>>where
M: MessageTrait + Send + Sync,
S: Fn(&[MessageQueue], &M, &T) -> Option<MessageQueue> + Send + Sync + 'static,
T: Send + Sync + 'static,
Sends a selector-routed request and waits for its reply. Read more
Source§async fn request_reply_selected_with_callback<M, S, T>(
&mut self,
request: SelectedRequestReplyCallbackRequest<M, S, T>,
) -> ClientResult<()>where
M: MessageTrait + Send + Sync,
S: Fn(&[MessageQueue], &M, &T) -> Option<MessageQueue> + Send + Sync + 'static,
T: Send + Sync + 'static,
async fn request_reply_selected_with_callback<M, S, T>(
&mut self,
request: SelectedRequestReplyCallbackRequest<M, S, T>,
) -> ClientResult<()>where
M: MessageTrait + Send + Sync,
S: Fn(&[MessageQueue], &M, &T) -> Option<MessageQueue> + Send + Sync + 'static,
T: Send + Sync + 'static,
Sends a selector-routed request and reports its reply through a callback. Read more
Auto Trait Implementations§
impl !RefUnwindSafe for DefaultMQProducer
impl !UnwindSafe for DefaultMQProducer
impl Freeze for DefaultMQProducer
impl Send for DefaultMQProducer
impl Sync for DefaultMQProducer
impl Unpin for DefaultMQProducer
impl UnsafeUnpin for DefaultMQProducer
Blanket Implementations§
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
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> FmtForward for T
impl<T> FmtForward for T
Source§fn fmt_binary(self) -> FmtBinary<Self>where
Self: Binary,
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,
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,
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,
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,
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,
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,
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,
fn fmt_upper_hex(self) -> FmtUpperHex<Self>where
Self: UpperHex,
Causes
self to use its UpperHex implementation when
Debug-formatted.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> Pipe for Twhere
T: ?Sized,
impl<T> Pipe for Twhere
T: ?Sized,
Source§fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> Rwhere
Self: Sized,
fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> Rwhere
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) -> Rwhere
R: 'a,
fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> Rwhere
R: 'a,
Borrows
self and passes that borrow into the pipe function. Read moreSource§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,
Mutably borrows
self and passes that borrow into the pipe function. Read moreSource§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
Source§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
Source§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
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
fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> R
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
fn pipe_deref<'a, T, R>(&'a self, func: impl FnOnce(&'a T) -> R) -> R
Borrows
self, then passes self.deref() into the pipe function.Source§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<T> Tap for T
impl<T> Tap for T
Source§fn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
fn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
Immutable access to the
Borrow<B> of a value. Read moreSource§fn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
fn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
Mutable access to the
BorrowMut<B> of a value. Read moreSource§fn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
fn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
Immutable access to the
AsRef<R> view of a value. Read moreSource§fn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
fn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
Mutable access to the
AsMut<R> view of a value. Read moreSource§fn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
fn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
Immutable access to the
Deref::Target of a value. Read moreSource§fn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
fn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
Mutable access to the
Deref::Target of a value. Read moreSource§fn tap_dbg(self, func: impl FnOnce(&Self)) -> Self
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
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
fn tap_borrow_dbg<B>(self, func: impl FnOnce(&B)) -> Self
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
fn tap_borrow_mut_dbg<B>(self, func: impl FnOnce(&mut B)) -> Self
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
fn tap_ref_dbg<R>(self, func: impl FnOnce(&R)) -> Self
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
fn tap_ref_mut_dbg<R>(self, func: impl FnOnce(&mut R)) -> Self
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
fn tap_deref_dbg<T>(self, func: impl FnOnce(&T)) -> Self
Calls
.tap_deref() only in debug builds, and is erased in release
builds.