Class PIMAddrGroup


  • public class PIMAddrGroup
    extends java.lang.Object
    • Field Detail

      • ENC_GROUP_IPV4_BYTE_LENGTH

        public static final int ENC_GROUP_IPV4_BYTE_LENGTH
        See Also:
        Constant Field Values
      • ENC_GROUP_IPV6_BYTE_LENGTH

        public static final int ENC_GROUP_IPV6_BYTE_LENGTH
        See Also:
        Constant Field Values
    • Constructor Detail

      • PIMAddrGroup

        public PIMAddrGroup()
        PIM Encoded Group Address.
      • PIMAddrGroup

        public PIMAddrGroup​(java.lang.String addr)
        PIM Encoded Source Address.
        Parameters:
        addr - IPv4 or IPv6
      • PIMAddrGroup

        public PIMAddrGroup​(IpPrefix gpfx)
        PIM Encoded Group Address.
        Parameters:
        gpfx - PIM encoded group address.
    • Method Detail

      • setAddr

        public void setAddr​(java.lang.String addr)
        PIM encoded source address.
        Parameters:
        addr - IPv4 or IPv6
      • setAddr

        public void setAddr​(IpPrefix pfx)
        Set the encoded source address.
        Parameters:
        pfx - address prefix
      • getFamily

        public int getFamily()
        Get the IP family of this address: 4 or 6.
        Returns:
        the IP address family
      • getAddr

        public IpAddress getAddr()
        Get the address of this encoded address.
        Returns:
        source address
      • getMasklen

        public int getMasklen()
        Get the masklen of the group address.
        Returns:
        the masklen
      • getZBit

        public boolean getZBit()
        Return the z bit for admin scoping. Only used for the Bootstrap router.
        Returns:
        true or false
      • getBBit

        public boolean getBBit()
        Return the bBit. Used to indicate this is a bidir
        Returns:
        return true or false.
      • getByteSize

        public int getByteSize()
        The size in bytes of a serialized address.
        Returns:
        the number of bytes when serialized
      • serialize

        public byte[] serialize()
        Serialize this group address.
        Returns:
        the serialized address in a buffer
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • equals

        public boolean equals​(java.lang.Object obj)
        Overrides:
        equals in class java.lang.Object