jnetpcap.capture
Enum LiveCapture.Option

java.lang.Object
  extended by java.lang.Enum<LiveCapture.Option>
      extended by jnetpcap.capture.LiveCapture.Option
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable<LiveCapture.Option>
Enclosing interface:
LiveCapture

public static enum LiveCapture.Option
extends java.lang.Enum<LiveCapture.Option>

Options which can be set on open captures. The options are only hints and may be ignored due to other reasons, such as some other capture has already put the interface into Promiscous mode, a condition which results in all packets being captured for all sessions even this one.

Author:
Mark Bednarczyk, Sly Technologies, Inc.

Enum Constant Summary
NonPropmiscous
          CaptureFactory only packets that are destined for the network interface.
Promiscous
          Forces all the packets to be captured on an interface, even if the packets are not destined for the network interface or the system.
 
Method Summary
static LiveCapture.Option valueOf(java.lang.String name)
          Returns the enum constant of this type with the specified name.
static LiveCapture.Option[] values()
          Returns an array containing the constants of this enum type, in the order they're declared.
 
Methods inherited from class java.lang.Enum
compareTo, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

Promiscous

public static final LiveCapture.Option Promiscous
Forces all the packets to be captured on an interface, even if the packets are not destined for the network interface or the system.


NonPropmiscous

public static final LiveCapture.Option NonPropmiscous
CaptureFactory only packets that are destined for the network interface.

Method Detail

values

public static final LiveCapture.Option[] values()
Returns an array containing the constants of this enum type, in the order they're declared. This method may be used to iterate over the constants as follows:
for(LiveCapture.Option c : LiveCapture.Option.values())
        System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they're declared

valueOf

public static LiveCapture.Option valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
java.lang.IllegalArgumentException - if this enum type has no constant with the specified name