org.opennms.protocols.ip
Class IPHeader.RouteOption

java.lang.Object
  extended by org.opennms.protocols.ip.IPHeader.Option
      extended by org.opennms.protocols.ip.IPHeader.RouteOption
Direct Known Subclasses:
IPHeader.LooseSourceRouteOption, IPHeader.RouteRecordOption, IPHeader.StrictSourceRouteOption
Enclosing class:
IPHeader

public static class IPHeader.RouteOption
extends IPHeader.Option

This class represents routing options that may be part of an IP header. The route defines a set of IP addresses that a packet may have or should pass though.

Author:
Brian Weaver , OpenNMS

Field Summary
protected  java.util.List<IPv4Address> m_addrs
          The list of addresses for the packet to hit on it's way to it's destination
 
Fields inherited from class org.opennms.protocols.ip.IPHeader.Option
CODE_END_OF_OPTION_LIST, CODE_LOOSE_SOURCE_ROUTE, CODE_ROUTE_RECORD, CODE_STRICT_SOURCE_ROUTE, m_code
 
Method Summary
 java.util.Iterator<IPv4Address> iterator()
          Returns the iterator that may be used to look at the encapsulated addresses.
 int size()
          Returns the number of addresses contained in the option list.
 
Methods inherited from class org.opennms.protocols.ip.IPHeader.Option
getOptionClass, getOptionNumber, isOptionCopied
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

m_addrs

protected java.util.List<IPv4Address> m_addrs
The list of addresses for the packet to hit on it's way to it's destination

Method Detail

iterator

public java.util.Iterator<IPv4Address> iterator()
Returns the iterator that may be used to look at the encapsulated addresses. The class IPv4Address is used to represent the addresses in the list.

Returns:
An iterator that can be used to operate on the list.

size

public int size()
Returns the number of addresses contained in the option list.



Copyright © 2007. All Rights Reserved.