pub struct UDP {
pub connection: Connection,
pub payload: Vec<u8>,
}Fields§
§connection: Connection§payload: Vec<u8>Implementations§
Source§impl UDP
impl UDP
pub fn new(source: SocketAddr, destination: SocketAddr, payload: Vec<u8>) -> UDP
pub fn from_packet(ip_connection: IpConnection, udp_packet: UDP_Packet) -> UDP
pub fn build(source_port: u16, destination_port: u16, payload: &[u8]) -> Vec<u8> ⓘ
pub fn build_ip_buffer(connection: Connection, payload: &[u8]) -> Vec<u8> ⓘ
Trait Implementations§
impl Eq for UDP
impl StructuralPartialEq for UDP
Auto Trait Implementations§
impl Freeze for UDP
impl RefUnwindSafe for UDP
impl Send for UDP
impl Sync for UDP
impl Unpin for UDP
impl UnwindSafe for UDP
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit)