pub struct PublisherSynchronousProxy { /* private fields */ }
Implementations§
Source§impl PublisherSynchronousProxy
impl PublisherSynchronousProxy
pub fn new(channel: Channel) -> Self
pub fn into_channel(self) -> Channel
Sourcepub fn wait_for_event(
&self,
deadline: MonotonicInstant,
) -> Result<PublisherEvent, Error>
pub fn wait_for_event( &self, deadline: MonotonicInstant, ) -> Result<PublisherEvent, Error>
Waits until an event arrives and returns it. It is safe for other threads to make concurrent requests while waiting for an event.
Sourcepub fn publish(
&self,
data_sink: &str,
data: Vmo,
vmo_token: EventPair,
) -> Result<(), Error>
pub fn publish( &self, data_sink: &str, data: Vmo, vmo_token: EventPair, ) -> Result<(), Error>
The program runtime sends a string naming a data_sink
and transfers
the handle to a VMO containing the data
it wants published
there. The data_sink
string identifies a type of data, and the
VMO’s object name can specifically identify the data set in this VMO.
The ZX_PROP_VMO_CONTENT_SIZE property should be set on the VMO to
indicate the precise size of the data in case that is not whole pages;
however, leaving it unset (i.e. 0) is acceptable when the whole-page
size of the VMO is the intended size of dump. Code instrumentation
runtimes use this to deliver large binary trace results. In such cases,
the client can resize the VMO and should use the vmo_token
handle to
signal when the VMO is ready for processing by the recipient. The
receiver will not process the VMO until the peer of vmo_token
handle
is closed. Therefore, the client should retain the peer handle until
it has completed all writes to the VMO.
Trait Implementations§
Source§impl Debug for PublisherSynchronousProxy
impl Debug for PublisherSynchronousProxy
Source§impl SynchronousProxy for PublisherSynchronousProxy
impl SynchronousProxy for PublisherSynchronousProxy
Source§type Proxy = PublisherProxy
type Proxy = PublisherProxy
Source§type Protocol = PublisherMarker
type Protocol = PublisherMarker
Proxy
controls.