Struct neutron::ProducerBuilder
source · pub struct ProducerBuilder<C, T>where
T: ProducerDataTrait,
C: PulsarClient,{ /* private fields */ }
Implementations§
source§impl<T> ProducerBuilder<Client, T>where
T: ProducerDataTrait,
impl<T> ProducerBuilder<Client, T>where
T: ProducerDataTrait,
pub fn new() -> Self
pub fn with_producer_name(self, producer_name: &str) -> Self
pub fn with_topic(self, topic: &str) -> Self
pub async fn connect( self, pulsar_manager: &PulsarManager ) -> Result<Producer<Client, T>, NeutronError>
Trait Implementations§
source§impl<T> Default for ProducerBuilder<Client, T>where
T: ProducerDataTrait,
impl<T> Default for ProducerBuilder<Client, T>where
T: ProducerDataTrait,
Auto Trait Implementations§
impl<C, T> Freeze for ProducerBuilder<C, T>
impl<C, T> RefUnwindSafe for ProducerBuilder<C, T>where
T: RefUnwindSafe,
C: RefUnwindSafe,
impl<C, T> Send for ProducerBuilder<C, T>where
C: Send,
impl<C, T> Sync for ProducerBuilder<C, T>where
C: Sync,
impl<C, T> Unpin for ProducerBuilder<C, T>
impl<C, T> UnwindSafe for ProducerBuilder<C, T>where
T: UnwindSafe,
C: UnwindSafe,
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> 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>
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 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>
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