pub struct UnixDomainSocketSynchronousProxy { /* private fields */ }
Implementations§
Source§impl UnixDomainSocketSynchronousProxy
impl UnixDomainSocketSynchronousProxy
pub fn new(channel: Channel) -> Self
pub fn into_channel(self) -> Channel
Sourcepub fn wait_for_event(
&self,
deadline: MonotonicInstant,
) -> Result<UnixDomainSocketEvent, Error>
pub fn wait_for_event( &self, deadline: MonotonicInstant, ) -> Result<UnixDomainSocketEvent, Error>
Waits until an event arrives and returns it. It is safe for other threads to make concurrent requests while waiting for an event.
pub fn clone(&self, request: ServerEnd<CloneableMarker>) -> Result<(), Error>
Sourcepub fn close(
&self,
___deadline: MonotonicInstant,
) -> Result<CloseableCloseResult, Error>
pub fn close( &self, ___deadline: MonotonicInstant, ) -> Result<CloseableCloseResult, Error>
Terminates the connection.
After calling Close
, the client must not send any other requests.
Servers, after sending the status response, should close the connection regardless of status and without sending an epitaph.
Closing the client end of the channel should be semantically equivalent
to calling Close
without knowing when the close has completed or its
status.
pub fn query(&self, ___deadline: MonotonicInstant) -> Result<Vec<u8>, Error>
Sourcepub fn get_event(
&self,
payload: &UnixDomainSocketGetEventRequest,
___deadline: MonotonicInstant,
) -> Result<UnixDomainSocketGetEventResult, Error>
pub fn get_event( &self, payload: &UnixDomainSocketGetEventRequest, ___deadline: MonotonicInstant, ) -> Result<UnixDomainSocketGetEventResult, Error>
Returns an EventPair that will allow Starnix to wait on the socket. This event must use:
fio.FileSignal.READABLE
to signal that a message is available.fio.FileSignal.WRITABLE
to signal that it can accept a new message.ZX_EVENTPAIR_PEER_CLOSED
to signal that it is closed.
Sourcepub fn read(
&self,
payload: &UnixDomainSocketReadRequest,
___deadline: MonotonicInstant,
) -> Result<UnixDomainSocketReadResult, Error>
pub fn read( &self, payload: &UnixDomainSocketReadRequest, ___deadline: MonotonicInstant, ) -> Result<UnixDomainSocketReadResult, Error>
Read a message from the socket.
Sourcepub fn write(
&self,
payload: UnixDomainSocketWriteRequest,
___deadline: MonotonicInstant,
) -> Result<UnixDomainSocketWriteResult, Error>
pub fn write( &self, payload: UnixDomainSocketWriteRequest, ___deadline: MonotonicInstant, ) -> Result<UnixDomainSocketWriteResult, Error>
Write a message to the socket.
Trait Implementations§
Source§impl SynchronousProxy for UnixDomainSocketSynchronousProxy
impl SynchronousProxy for UnixDomainSocketSynchronousProxy
Source§type Proxy = UnixDomainSocketProxy
type Proxy = UnixDomainSocketProxy
The async proxy for the same protocol.
Source§type Protocol = UnixDomainSocketMarker
type Protocol = UnixDomainSocketMarker
The protocol which this
Proxy
controls.Source§fn from_channel(inner: Channel) -> Self
fn from_channel(inner: Channel) -> Self
Create a proxy over the given channel.
Source§fn into_channel(self) -> Channel
fn into_channel(self) -> Channel
Convert the proxy back into a channel.
Source§fn as_channel(&self) -> &Channel
fn as_channel(&self) -> &Channel
Get a reference to the proxy’s underlying channel. Read more
Auto Trait Implementations§
impl Freeze for UnixDomainSocketSynchronousProxy
impl RefUnwindSafe for UnixDomainSocketSynchronousProxy
impl Send for UnixDomainSocketSynchronousProxy
impl Sync for UnixDomainSocketSynchronousProxy
impl Unpin for UnixDomainSocketSynchronousProxy
impl UnwindSafe for UnixDomainSocketSynchronousProxy
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