Module inet.ipaddr

Class IPv6AddressSection.IPv6v4MixedAddressSection

All Implemented Interfaces:
AddressDivisionSeries, AddressItem, IPAddressDivisionSeries, AddressStringDivisionSeries, IPAddressStringDivisionSeries, Serializable, Comparable<AddressItem>
Enclosing class:
IPv6AddressSection

public static class IPv6AddressSection.IPv6v4MixedAddressSection extends IPAddressDivisionGrouping
See Also:
  • Method Details

    • getByteCount

      public int getByteCount()
      Description copied from interface: AddressItem
      Provides the number of bytes required for this address item, rounding up if the bit count is not a multiple of 8
      Returns:
      the number of bytes
    • getBitCount

      public int getBitCount()
      Description copied from interface: AddressItem
      Provides the number of bits comprising this address item
      Returns:
      the number of bits
    • isPrefixBlock

      public boolean isPrefixBlock()
      Description copied from class: IPAddressDivisionGrouping
      Returns whether this address section represents a subnet block of addresses associated its prefix length. Returns false if it has no prefix length, if it is a single address with a prefix length (ie not a subnet), or if it is a range of addresses that does not include the entire subnet block for its prefix length. If AddressNetwork.getPrefixConfiguration() is set to consider all prefixes as subnets, this returns true for any grouping with prefix length.
      Specified by:
      isPrefixBlock in interface AddressDivisionSeries
      Specified by:
      isPrefixBlock in interface IPAddressStringDivisionSeries
      Overrides:
      isPrefixBlock in class IPAddressDivisionGrouping
      Returns:
    • toString

      public String toString()
      Overrides:
      toString in class AddressDivisionGroupingBase
    • equals

      public boolean equals(Object o)
      Description copied from class: AddressDivisionGroupingBase
      Two groupings are equal if: - they match type/version (ipv4, ipv6, mac, or a specific grouping class) - they match division counts - each division matches bit counts - each division matches their specific grouping class - each division matches values Prefix lengths, for those groupings and/or divisionsS that have them, are ignored.
      Overrides:
      equals in class IPAddressDivisionGrouping