public final class IPAddrRange extends Object implements Iterable<InetAddress>
The IPAddressRange object is used to encapsulate the starting and ending points of a contiguous IPv4/IPv6 Address range. The class can then generate either an Enumeration or Iterator that can be used to cycle through the range of addresses by the object's user.
Modifier and Type | Method and Description |
---|---|
Iterator<InetAddress> |
iterator()
Returns an Iterator object that can be used to step through all the
address encapsulated in the object.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
forEach, spliterator
public Iterator<InetAddress> iterator()
Returns an Iterator object that can be used to step through all the address encapsulated in the object.
The iterator returns objects of type
InetAddress
or null
if the
address is unknown.
iterator
in interface Iterable<InetAddress>
Iterator
object.InetAddress
Copyright © 2015. All rights reserved.