/smoltcp-0.9.1/src/wire/ |
D | ipv4.rs | 33 src_addr: Address, 34 dst_addr: Address, 40 pub struct Address(pub [u8; ADDR_SIZE]); struct 42 impl Address { impl 44 pub const UNSPECIFIED: Address = Address([0x00; ADDR_SIZE]); 47 pub const BROADCAST: Address = Address([0xff; ADDR_SIZE]); 50 pub const MULTICAST_ALL_SYSTEMS: Address = Address([224, 0, 0, 1]); 53 pub const MULTICAST_ALL_ROUTERS: Address = Address([224, 0, 0, 2]); 56 pub const fn new(a0: u8, a1: u8, a2: u8, a3: u8) -> Address { in new() argument 57 Address([a0, a1, a2, a3]) in new() [all …]
|
D | ipv6.rs | 31 pub struct Address(pub [u8; ADDR_SIZE]); struct 33 impl Address { impl 37 pub const UNSPECIFIED: Address = Address([0x00; ADDR_SIZE]); 42 pub const LINK_LOCAL_ALL_NODES: Address = Address([ 50 pub const LINK_LOCAL_ALL_ROUTERS: Address = Address([ 58 pub const LOOPBACK: Address = Address([ 80 ) -> Address { in new() argument 81 Address([ in new() 105 pub fn from_bytes(data: &[u8]) -> Address { in from_bytes() argument 108 Address(bytes) in from_bytes() [all …]
|
D | ip.rs | 84 pub enum Address { enum 93 impl Address { impl 96 pub const fn v4(a0: u8, a1: u8, a2: u8, a3: u8) -> Address { in v4() argument 97 Address::Ipv4(Ipv4Address::new(a0, a1, a2, a3)) in v4() 103 pub fn v6(a0: u16, a1: u16, a2: u16, a3: u16, a4: u16, a5: u16, a6: u16, a7: u16) -> Address { in v6() argument 104 Address::Ipv6(Ipv6Address::new(a0, a1, a2, a3, a4, a5, a6, a7)) in v6() 111 Address::Ipv4(_) => Version::Ipv4, in version() 113 Address::Ipv6(_) => Version::Ipv6, in version() 121 Address::Ipv4(addr) => addr.as_bytes(), in as_bytes() 123 Address::Ipv6(addr) => addr.as_bytes(), in as_bytes() [all …]
|
D | ethernet.rs | 29 pub struct Address(pub [u8; 6]); struct 31 impl Address { impl 33 pub const BROADCAST: Address = Address([0xff; 6]); 39 pub fn from_bytes(data: &[u8]) -> Address { in from_bytes() argument 42 Address(bytes) in from_bytes() 71 impl fmt::Display for Address { implementation 146 pub fn dst_addr(&self) -> Address { in dst_addr() argument 148 Address::from_bytes(&data[field::DESTINATION]) in dst_addr() 153 pub fn src_addr(&self) -> Address { in src_addr() argument 155 Address::from_bytes(&data[field::SOURCE]) in src_addr() [all …]
|
D | ieee802154.rs | 6 use crate::wire::ipv6::Address as Ipv6Address; 86 pub enum Address { enum 93 impl Default for Address { implementation 95 Address::Extended([0u8; 8]) in default() 99 impl Address { impl 101 pub const BROADCAST: Address = Address::Short([0xff; 2]); 125 Address::Short(b) in from_bytes() 129 Address::Extended(b) in from_bytes() 137 Address::Absent => &[], in as_bytes() 138 Address::Short(value) => value, in as_bytes() [all …]
|
D | sixlowpan.rs | 7 use crate::wire::ieee802154::Address as LlAddress; 65 ) -> Result<ipv6::Address> { in resolve() argument 81 AddressMode::FullInline(addr) => Ok(ipv6::Address::from_bytes(addr)), in resolve() 85 Ok(ipv6::Address::from_bytes(&bytes[..])) in resolve() 91 Ok(ipv6::Address::from_bytes(&bytes[..])) in resolve() 107 Ok(ipv6::Address::from_bytes(&bytes[..])) in resolve() 113 Ok(ipv6::Address::from_bytes(&bytes[..])) in resolve() 119 Ok(ipv6::Address::from_bytes(&bytes[..])) in resolve() 125 Ok(ipv6::Address::from_bytes(&bytes[..])) in resolve() 130 (_, AddressMode::Unspecified) => Ok(ipv6::Address::UNSPECIFIED), in resolve() [all …]
|
D | ipv6routing.rs | 5 use crate::wire::Ipv6Address as Address; 227 pub fn home_address(&self) -> Address { in home_address() argument 229 Address::from_bytes(&data[field::HOME_ADDRESS]) in home_address() 336 pub fn set_home_address(&mut self, value: Address) { in set_home_address() argument 410 home_address: Address, 555 home_address: Address::LOOPBACK, 618 assert_eq!(header.home_address(), Address::LOOPBACK); in test_header_deconstruct()
|
D | mod.rs | 136 Address as EthernetAddress, EtherType as EthernetProtocol, Frame as EthernetFrame, 159 Address as Ieee802154Address, AddressingMode as Ieee802154AddressingMode, 165 Address as IpAddress, Cidr as IpCidr, Endpoint as IpEndpoint, 172 Address as Ipv4Address, Cidr as Ipv4Cidr, Key as Ipv4FragKey, Packet as Ipv4Packet, 178 Address as Ipv6Address, Cidr as Ipv6Cidr, Packet as Ipv6Packet, Repr as Ipv6Repr,
|