pub struct PublisherBuilder<'a, 'b> { /* private fields */ }Expand description
A builder for initializing a Publisher.
Returned by the
Session::declare_publisher method.
§Examples
use zenoh::qos::CongestionControl;
let session = zenoh::open(zenoh::Config::default()).await.unwrap();
let publisher = session
.declare_publisher("key/expression")
.congestion_control(CongestionControl::Block)
.await
.unwrap();Implementations§
Source§impl PublisherBuilder<'_, '_>
impl PublisherBuilder<'_, '_>
Source§impl PublisherBuilder<'_, '_>
impl PublisherBuilder<'_, '_>
Sourcepub fn congestion_control(self, congestion_control: CongestionControl) -> Self
pub fn congestion_control(self, congestion_control: CongestionControl) -> Self
Changes the CongestionControl to apply when routing the data.
Source§impl PublisherBuilder<'_, '_>
impl PublisherBuilder<'_, '_>
Sourcepub fn allowed_destination(self, destination: Locality) -> Self
pub fn allowed_destination(self, destination: Locality) -> Self
Sourcepub fn reliability(self, reliability: Reliability) -> Self
Available on crate feature unstable only.
pub fn reliability(self, reliability: Reliability) -> Self
unstable only.Changes the Reliability to apply when routing the data.
This API has been marked as unstable: it works as advertised, but it may be changed in a future release.
NOTE: Currently reliability does not trigger any data retransmission on the wire. It
is rather used as a marker on the wire and it may be used to select the best link
available (e.g. TCP for reliable data and UDP for best effort data).
Trait Implementations§
Source§impl Clone for PublisherBuilder<'_, '_>
impl Clone for PublisherBuilder<'_, '_>
Source§impl<'a, 'b> Debug for PublisherBuilder<'a, 'b>
impl<'a, 'b> Debug for PublisherBuilder<'a, 'b>
Source§impl IntoFuture for PublisherBuilder<'_, '_>
impl IntoFuture for PublisherBuilder<'_, '_>
Source§type Output = <PublisherBuilder<'_, '_> as Resolvable>::To
type Output = <PublisherBuilder<'_, '_> as Resolvable>::To
The output that the future will produce on completion.
Source§type IntoFuture = Ready<<PublisherBuilder<'_, '_> as Resolvable>::To>
type IntoFuture = Ready<<PublisherBuilder<'_, '_> as Resolvable>::To>
Which kind of future are we turning this into?
Source§fn into_future(self) -> Self::IntoFuture
fn into_future(self) -> Self::IntoFuture
Creates a future from a value. Read more
Source§impl<'b> Resolvable for PublisherBuilder<'_, 'b>
impl<'b> Resolvable for PublisherBuilder<'_, 'b>
Source§impl Wait for PublisherBuilder<'_, '_>
impl Wait for PublisherBuilder<'_, '_>
Source§fn wait(self) -> <Self as Resolvable>::To
fn wait(self) -> <Self as Resolvable>::To
Synchronously execute and wait
Auto Trait Implementations§
impl<'a, 'b> Freeze for PublisherBuilder<'a, 'b>
impl<'a, 'b> !RefUnwindSafe for PublisherBuilder<'a, 'b>
impl<'a, 'b> Send for PublisherBuilder<'a, 'b>
impl<'a, 'b> Sync for PublisherBuilder<'a, 'b>
impl<'a, 'b> Unpin for PublisherBuilder<'a, 'b>
impl<'a, 'b> !UnwindSafe for PublisherBuilder<'a, 'b>
Blanket Implementations§
Source§impl<Source> AccessAs for Source
impl<Source> AccessAs for Source
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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> 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