org.jnetstream.packet
Enum Packet.Property

java.lang.Object
  extended by java.lang.Enum<Packet.Property>
      extended by org.jnetstream.packet.Packet.Property
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable<Packet.Property>
Enclosing interface:
Packet

public static enum Packet.Property
extends java.lang.Enum<Packet.Property>

Properties which are autogenerated or exported from NPL definition.

Author:
Mark Bednarczyk, Sly Technologies, Inc.

Enum Constant Summary
DestinationAddress
          Destination address of this packet as exported by the highest OSI level header
DestinationPort
          Destination port number of this packet, if exists, of the highest level OSI level header
FlowKey
           Flow key associated with this packet.
Included
          Included length property holds the number of bytes that were captured for the packet which may be less then the original size of the packet.
Index
          Raw index of this packet as it was captured, read or created
Init
          Special property that is used to initialize fields when packet is created from memory.
LongSummary
           
Nanos
          The capture timestamp contains a fraction of a second, specified in nano seconds of exactly when the packet was captured.
Original
          Original length property holds the original size of the packet when it was captured on the wire.
Seconds
          Timestamp seconds property as a unix timestamp.
ShortSummary
           
SourceAddress
          Source address of this packet as exported by the highest OSI level header
SourcePort
          Source port number of this packet, if exists, of the highest level OSI level header
Timestamp
          A readonly Property which combines the Seconds and Nanos properties into a single object which can display the value nicely formatted.
 
Method Summary
 java.lang.Class<?> getValueType()
          Returns the class that must be used to hold the value of this property
static Packet.Property valueOf(java.lang.String name)
          Returns the enum constant of this type with the specified name.
static Packet.Property[] values()
          Returns an array containing the constants of this enum type, in the order they're declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

Init

public static final Packet.Property Init
Special property that is used to initialize fields when packet is created from memory.


Included

public static final Packet.Property Included
Included length property holds the number of bytes that were captured for the packet which may be less then the original size of the packet. Can be used in the Packet.getProperty call.


Original

public static final Packet.Property Original
Original length property holds the original size of the packet when it was captured on the wire. The packet may have been truncated afterwards. Can be used in the Packet.getProperty call.


Seconds

public static final Packet.Property Seconds
Timestamp seconds property as a unix timestamp. The capture timestamp contains number of a second since a common time of exactly when the packet was captured. The actual accuracy of the nanos timestamp component is hardware dependent. Can be used in the Packet.getProperty call.


Nanos

public static final Packet.Property Nanos
The capture timestamp contains a fraction of a second, specified in nano seconds of exactly when the packet was captured. The actual accuracy of the nanos timestamp component is hardware dependent. Even when the hardware is only capable of recording micro-second timestamp resolution, the micro second fraction is converted to nanos. Can be used in the Packet.getProperty call.


Timestamp

public static final Packet.Property Timestamp
A readonly Property which combines the Seconds and Nanos properties into a single object which can display the value nicely formatted. Type Timestamp.class.


SourceAddress

public static final Packet.Property SourceAddress
Source address of this packet as exported by the highest OSI level header


DestinationAddress

public static final Packet.Property DestinationAddress
Destination address of this packet as exported by the highest OSI level header


SourcePort

public static final Packet.Property SourcePort
Source port number of this packet, if exists, of the highest level OSI level header


DestinationPort

public static final Packet.Property DestinationPort
Destination port number of this packet, if exists, of the highest level OSI level header


FlowKey

public static final Packet.Property FlowKey

Flow key associated with this packet.

TODO: Change the Object.class to FlowKey class when implemented


Index

public static final Packet.Property Index
Raw index of this packet as it was captured, read or created


LongSummary

public static final Packet.Property LongSummary

ShortSummary

public static final Packet.Property ShortSummary
Method Detail

values

public static final Packet.Property[] 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(Packet.Property c : Packet.Property.values())
        System.out.println(c);

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

valueOf

public static Packet.Property 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

getValueType

public java.lang.Class<?> getValueType()
Returns the class that must be used to hold the value of this property

Returns:
class object of the value type