pub struct ElectLeadersRequestBuilder { /* private fields */ }
Expand description
Builder for ElectLeadersRequest
.
Implementations§
source§impl ElectLeadersRequestBuilder
impl ElectLeadersRequestBuilder
sourcepub fn election_type(&mut self, value: i8) -> &mut Self
pub fn election_type(&mut self, value: i8) -> &mut Self
Type of elections to conduct for the partition. A value of ‘0’ elects the preferred replica. A value of ‘1’ elects the first live replica if there are no in-sync replica.
Supported API versions: 1-2
sourcepub fn topic_partitions(
&mut self,
value: Option<IndexMap<TopicName, TopicPartitions>>
) -> &mut Self
pub fn topic_partitions( &mut self, value: Option<IndexMap<TopicName, TopicPartitions>> ) -> &mut Self
The topic partitions to elect leaders.
Supported API versions: 0-2
sourcepub fn timeout_ms(&mut self, value: i32) -> &mut Self
pub fn timeout_ms(&mut self, value: i32) -> &mut Self
The time in ms to wait for the election to complete.
Supported API versions: 0-2
sourcepub fn unknown_tagged_fields(
&mut self,
value: BTreeMap<i32, Vec<u8>>
) -> &mut Self
pub fn unknown_tagged_fields( &mut self, value: BTreeMap<i32, Vec<u8>> ) -> &mut Self
Other tagged fields
sourcepub fn build(
&self
) -> Result<ElectLeadersRequest, ElectLeadersRequestBuilderError>
pub fn build( &self ) -> Result<ElectLeadersRequest, ElectLeadersRequestBuilderError>
Trait Implementations§
source§impl Clone for ElectLeadersRequestBuilder
impl Clone for ElectLeadersRequestBuilder
source§fn clone(&self) -> ElectLeadersRequestBuilder
fn clone(&self) -> ElectLeadersRequestBuilder
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl RefUnwindSafe for ElectLeadersRequestBuilder
impl Send for ElectLeadersRequestBuilder
impl Sync for ElectLeadersRequestBuilder
impl Unpin for ElectLeadersRequestBuilder
impl UnwindSafe for ElectLeadersRequestBuilder
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