pub(super) struct Common {
socket: BoxedSplit,
recv_buffer: Vec<u8>,
received_fds: Vec<OwnedFd>,
cap_unix_fd: bool,
mechanism: AuthMechanism,
first_command: bool,
}Fields§
§socket: BoxedSplit§recv_buffer: Vec<u8>§received_fds: Vec<OwnedFd>§cap_unix_fd: bool§mechanism: AuthMechanism§first_command: boolImplementations§
Source§impl Common
impl Common
Sourcepub fn new(socket: BoxedSplit, mechanism: AuthMechanism) -> Self
pub fn new(socket: BoxedSplit, mechanism: AuthMechanism) -> Self
Start a handshake on this client socket
pub fn socket_mut(&mut self) -> &mut BoxedSplit
pub fn set_cap_unix_fd(&mut self, cap_unix_fd: bool)
pub fn mechanism(&self) -> AuthMechanism
pub fn into_components( self, ) -> (BoxedSplit, Vec<u8>, Vec<OwnedFd>, bool, AuthMechanism)
pub async fn write_command(&mut self, command: Command) -> Result<()>
pub async fn write_commands( &mut self, commands: &[Command], extra_bytes: Option<&[u8]>, ) -> Result<()>
pub async fn read_command(&mut self) -> Result<Command>
pub async fn read_commands(&mut self, n_commands: usize) -> Result<Vec<Command>>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Common
impl !RefUnwindSafe for Common
impl Send for Common
impl Sync for Common
impl Unpin for Common
impl !UnwindSafe for Common
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