Struct socks5_impl::protocol::Response
source · pub struct Response {
pub reply: Reply,
pub address: Address,
}
Expand description
Response
+-----+-----+-------+------+----------+----------+
| VER | REP | RSV | ATYP | BND.ADDR | BND.PORT |
+-----+-----+-------+------+----------+----------+
| 1 | 1 | X'00' | 1 | Variable | 2 |
+-----+-----+-------+------+----------+----------+
Fields§
§reply: Reply
§address: Address
Implementations§
source§impl Response
impl Response
pub fn new(reply: Reply, address: Address) -> Self
pub async fn from_stream<R: AsyncRead + Unpin>(r: &mut R) -> Result<Self>
pub async fn write_to<W: AsyncWrite + Unpin>(&self, w: &mut W) -> Result<()>
pub fn write_to_buf<B: BufMut>(&self, buf: &mut B)
pub fn serialized_len(&self) -> usize
Trait Implementations§
Auto Trait Implementations§
impl RefUnwindSafe for Response
impl Send for Response
impl Sync for Response
impl Unpin for Response
impl UnwindSafe for Response
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