Entities
The classes which performs the Zenoh network operations
-
class Publisher : public zenohcxx::Owned<::z_owned_publisher_t>
An owned zenoh publisher. Constructed by
Session::declare_publisher
method.Methods
-
bool put(const zenoh::BytesView &payload, const zenoh::PublisherPutOptions &options, ErrNo &error)
Publish the payload.
- Parameters:
payload –
Payload
to publishoptions –
PublisherPutOptions
error – the error code
zenoh::ErrNo
- Returns:
true if the payload was published, false otherwise
-
bool put(const zenoh::BytesView &payload, ErrNo &error)
Publish the payload.
- Parameters:
payload –
Payload
to publisherror – the error code
zenoh::ErrNo
- Returns:
true if the payload was published, false otherwise
-
bool put(const zenoh::BytesView &payload, const zenoh::PublisherPutOptions &options)
Publish the payload.
- Parameters:
payload –
Payload
to publishoptions –
PublisherPutOptions
- Returns:
true if the payload was published, false otherwise
-
bool put(const zenoh::BytesView &payload)
Publish the payload.
- Parameters:
payload –
Payload
to publish- Returns:
true if the payload was published, false otherwise
-
bool delete_resource(const zenoh::PublisherDeleteOptions &options, ErrNo &error)
Undeclare the resource.
- Parameters:
options –
PublisherDeleteOptions
error – the error code
zenoh::ErrNo
- Returns:
true if the request was sent, false otherwise
-
bool delete_resource(ErrNo &error)
Undeclare the resource.
- Parameters:
error – the error code
zenoh::ErrNo
- Returns:
true if the request was sent, false otherwise
-
bool delete_resource(const zenoh::PublisherDeleteOptions &options)
Undeclare the resource.
- Parameters:
options –
PublisherDeleteOptions
- Returns:
true if the request was sent, false otherwise
-
bool delete_resource()
Send a delete request.
- Returns:
true if the request was sent, false otherwise
-
inline zenoh::KeyExpr get_keyexpr() const
Get the key expression of the publisher.
- Returns:
zenoh::KeyExpr
value
-
bool put_owned(zenoh::Payload &&payload, const zenoh::PublisherPutOptions &options, ErrNo &error)
Publish the payload got from
ShmBuf
or fromSample
- Parameters:
payload –
Payload
to publishoptions –
PublisherPutOptions
error – the error code
zenoh::ErrNo
- Returns:
true if the payload was published, false otherwise
Note
zenoh-c only
-
bool put_owned(zenoh::Payload &&payload, ErrNo &error)
Publish the payload got from
ShmBuf
or fromSample
- Parameters:
payload –
Payload
to publisherror – the error code
zenoh::ErrNo
- Returns:
true if the payload was published, false otherwise
Note
zenoh-c only
-
bool put_owned(zenoh::Payload &&payload, const zenoh::PublisherPutOptions &options)
Publish the payload got from
ShmBuf
or fromSample
- Parameters:
payload –
Payload
to publishoptions –
PublisherPutOptions
- Returns:
true if the payload was published, false otherwise
Note
zenoh-c only
-
bool put(const zenoh::BytesView &payload, const zenoh::PublisherPutOptions &options, ErrNo &error)
-
class Subscriber : public zenohcxx::Owned<::z_owned_subscriber_t>
An owned zenoh subscriber. Destroying subscriber cancels the subscription Constructed by
Session::declare_subscriber
method
-
class PullSubscriber : public zenohcxx::Owned<::z_owned_pull_subscriber_t>
An owned zenoh pull subscriber. Destroying the subscriber cancels the subscription. Constructed by
Session::declare_pull_subscriber
method
-
class Queryable : public zenohcxx::Owned<::z_owned_queryable_t>
An owned zenoh queryable. Constructed by
Session::declare_queryable
method.