final class Ipv4Address extends IpAddress with Ipv4AddressPlatform

Representation of an IPv4 address that works on both the JVM and Scala.js.

Source
Host.scala
Linear Supertypes
Ipv4AddressPlatform, IpAddress, Serializable, Host, Ordered[Host], Comparable[Host], HostPlatform, IpAddressPlatform, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. Ipv4Address
  2. Ipv4AddressPlatform
  3. IpAddress
  4. Serializable
  5. Host
  6. Ordered
  7. Comparable
  8. HostPlatform
  9. IpAddressPlatform
  10. AnyRef
  11. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##: Int
    Definition Classes
    AnyRef → Any
  3. def /(prefixBits: Int): Cidr[Ipv4Address.this.type]

    Constructs a Cidr address from this address.

    Constructs a Cidr address from this address.

    Definition Classes
    IpAddress
  4. def <(that: Host): Boolean
    Definition Classes
    Ordered
  5. def <=(that: Host): Boolean
    Definition Classes
    Ordered
  6. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  7. def >(that: Host): Boolean
    Definition Classes
    Ordered
  8. def >=(that: Host): Boolean
    Definition Classes
    Ordered
  9. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  10. def asIpv4: Option[Ipv4Address]

    Narrows this address to an Ipv4Address if that is the underlying type.

    Narrows this address to an Ipv4Address if that is the underlying type.

    Definition Classes
    IpAddress
  11. def asIpv6: Option[Ipv6Address]

    Narrows this address to an Ipv6Address if that is the underlying type.

    Narrows this address to an Ipv6Address if that is the underlying type.

    Definition Classes
    IpAddress
  12. def asMulticast: Option[Multicast[Ipv4Address.this.type]]

    Converts this address to a multicast address, as long as it is in the multicast address range.

    Converts this address to a multicast address, as long as it is in the multicast address range.

    Definition Classes
    IpAddress
  13. def asSourceSpecificMulticast: Option[SourceSpecificMulticast[Ipv4Address.this.type]]

    Converts this address to a source specific multicast address, as long as it is in the source specific multicast address range.

    Converts this address to a source specific multicast address, as long as it is in the source specific multicast address range.

    Definition Classes
    IpAddress
  14. val bytes: Array[Byte]
    Attributes
    protected
    Definition Classes
    Ipv4Address → Ipv4AddressPlatform → IpAddress
  15. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native()
  16. def collapseMappedV4: IpAddress

    If this address is an IPv4 mapped IPv6 address, converts to an IPv4 address, otherwise returns this.

    If this address is an IPv4 mapped IPv6 address, converts to an IPv4 address, otherwise returns this.

    Definition Classes
    IpAddress
  17. def compare(that: Host): Int
    Definition Classes
    Host → Ordered
  18. def compareTo(that: Host): Int
    Definition Classes
    Ordered → Comparable
  19. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  20. def equals(other: Any): Boolean
    Definition Classes
    IpAddress → AnyRef → Any
  21. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable])
  22. def fold[A](v4: (Ipv4Address) => A, v6: (Ipv6Address) => A): A

    Converts this address to a value of type A using the supplied functions.

    Converts this address to a value of type A using the supplied functions.

    Definition Classes
    Ipv4AddressIpAddress
  23. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  24. def hashCode(): Int
    Definition Classes
    IpAddress → AnyRef → Any
  25. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  26. def isMappedV4: Boolean

    Returns true if this address is a V6 address containing a mapped V4 address.

    Returns true if this address is a V6 address containing a mapped V4 address.

    Definition Classes
    IpAddress
  27. def isMulticast: Boolean

    Returns true if this address is in the multicast range.

    Returns true if this address is in the multicast range.

    Definition Classes
    Ipv4AddressIpAddress
  28. def isSourceSpecificMulticast: Boolean

    Returns true if this address is in the source specific multicast range.

    Returns true if this address is in the source specific multicast range.

    Definition Classes
    Ipv4AddressIpAddress
  29. def masked(mask: Ipv4Address): Ipv4Address

    Applies the supplied mask to this address.

    Applies the supplied mask to this address.

    Example:
    1. scala> ipv4"192.168.29.1".masked(ipv4"255.255.0.0")
      res0: Ipv4Address = 192.168.0.0
  30. def maskedLast(mask: Ipv4Address): Ipv4Address

    Computes the last address in the network identified by applying the supplied mask to this address.

    Computes the last address in the network identified by applying the supplied mask to this address.

    Example:
    1. scala> ipv4"192.168.29.1".maskedLast(ipv4"255.255.0.0")
      res0: Ipv4Address = 192.168.255.255
  31. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  32. def next: Ipv4Address

    Gets the IPv4 address after this address, with overflow from 255.255.255.255 to 0.0.0.0.

    Gets the IPv4 address after this address, with overflow from 255.255.255.255 to 0.0.0.0.

    Definition Classes
    Ipv4AddressIpAddress
  33. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  34. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  35. def previous: Ipv4Address

    Gets the IPv4 address before this address, with underflow from 0.0.0.0 to 255.255.255.255.

    Gets the IPv4 address before this address, with underflow from 0.0.0.0 to 255.255.255.255.

    Definition Classes
    Ipv4AddressIpAddress
  36. def resolve[F[_]](implicit arg0: Dns[F], arg1: Applicative[F]): F[IpAddress]

    Resolves this host to an ip address using the platform DNS resolver.

    Resolves this host to an ip address using the platform DNS resolver.

    If the host cannot be resolved, the effect fails with a java.net.UnknownHostException.

    Definition Classes
    HostPlatform
  37. def resolveAll[F[_]](implicit arg0: Dns[F], arg1: Applicative[F]): F[List[IpAddress]]

    Resolves this host to all ip addresses known to the platform DNS resolver.

    Resolves this host to all ip addresses known to the platform DNS resolver.

    If the host cannot be resolved, an empty list is returned.

    Definition Classes
    HostPlatform
  38. def resolveOption[F[_]](implicit arg0: Dns[F], arg1: ApplicativeThrow[F]): F[Option[IpAddress]]

    Resolves this host to an ip address using the platform DNS resolver.

    Resolves this host to an ip address using the platform DNS resolver.

    If the host cannot be resolved, a None is returned.

    Definition Classes
    HostPlatform
  39. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  40. def toBytes: Array[Byte]

    Converts this address to a network order byte array of either 4 or 16 bytes.

    Converts this address to a network order byte array of either 4 or 16 bytes.

    Definition Classes
    IpAddress
  41. def toCompatV6: Ipv6Address

    Converts this V4 address to a compat V6 address, where the first 12 bytes are all zero and the last 4 bytes contain the bytes of this V4 address.

  42. def toInetAddress: Inet4Address

    Converts this address to a java.net.InetAddress.

    Converts this address to a java.net.InetAddress. Note this method only exists on the JVM.

    Definition Classes
    Ipv4AddressPlatform → IpAddressPlatform
  43. def toLong: Long

    Converts this address to a 32-bit unsigned integer.

  44. def toMappedV6: Ipv6Address

    Converts this V4 address to a mapped V6 address, where the first 10 bytes are all zero, the next two bytes are ff, and the last 4 bytes contain the bytes of this V4 address.

  45. def toString(): String

    Returns the dotted decimal representation of this address.

    Returns the dotted decimal representation of this address.

    Definition Classes
    Ipv4Address → AnyRef → Any
  46. def toUriString: String

    Converts this address to a string form that is compatible for use in a URI per RFC3986 (namely, IPv6 addresses are rendered in condensed form and surrounded by brackets).

    Converts this address to a string form that is compatible for use in a URI per RFC3986 (namely, IPv6 addresses are rendered in condensed form and surrounded by brackets).

    Definition Classes
    Ipv4AddressIpAddress
  47. def transform(v4: (Ipv4Address) => Ipv4Address, v6: (Ipv6Address) => Ipv6Address): Ipv4Address.this.type

    Maps a type-preserving function across this IP address.

    Maps a type-preserving function across this IP address.

    Definition Classes
    Ipv4AddressIpAddress
  48. def version: IpVersion

    Returns the version of this address.

    Returns the version of this address.

    Definition Classes
    IpAddress
  49. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  50. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  51. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()

Inherited from Ipv4AddressPlatform

Inherited from IpAddress

Inherited from Serializable

Inherited from Host

Inherited from Ordered[Host]

Inherited from Comparable[Host]

Inherited from HostPlatform

Inherited from IpAddressPlatform

Inherited from AnyRef

Inherited from Any

Ungrouped