Trait IpBitwiseExt

Source
pub trait IpBitwiseExt<Rhs = Self> {
    type Output;

    // Required methods
    fn bitand(self, rhs: Rhs) -> Self::Output;
    fn bitor(self, rhs: Rhs) -> Self::Output;
    fn bitxor(self, rhs: Rhs) -> Self::Output;
}
Expand description

An extension trait providing bitwise binary operations for Ipv4Addr and Ipv6Addr types.

Required Associated Types§

Source

type Output

The output type of this operation.

Required Methods§

Source

fn bitand(self, rhs: Rhs) -> Self::Output

Bitwise And operation.

Source

fn bitor(self, rhs: Rhs) -> Self::Output

Bitwise Or operation.

Source

fn bitxor(self, rhs: Rhs) -> Self::Output

Bitwise Xor operation.

Implementations on Foreign Types§

Source§

impl IpBitwiseExt for Ipv4Addr

Source§

type Output = Ipv4Addr

Source§

fn bitand(self, rhs: Self) -> Self

Source§

fn bitor(self, rhs: Self) -> Self

Source§

fn bitxor(self, rhs: Self) -> Self

Source§

impl IpBitwiseExt<u32> for Ipv4Addr

Source§

type Output = Ipv4Addr

Source§

fn bitand(self, rhs: u32) -> Self

Source§

fn bitor(self, rhs: u32) -> Self

Source§

fn bitxor(self, rhs: u32) -> Self

Source§

impl IpBitwiseExt<Ipv4Mask> for Ipv4Addr

Source§

type Output = Ipv4Addr

Source§

fn bitand(self, rhs: Ipv4Mask) -> Self

Source§

fn bitor(self, rhs: Ipv4Mask) -> Self

Source§

fn bitxor(self, rhs: Ipv4Mask) -> Self

Source§

impl IpBitwiseExt<[u8; 4]> for Ipv4Addr

Source§

type Output = Ipv4Addr

Source§

fn bitand(self, rhs: [u8; 4]) -> Self

Source§

fn bitor(self, rhs: [u8; 4]) -> Self

Source§

fn bitxor(self, rhs: [u8; 4]) -> Self

Implementors§