org.jnetstream.capture.file.pcap
Interface PcapPacket

All Superinterfaces:
CapturePacket, FilePacket, java.lang.Iterable<Header>, Packet

public interface PcapPacket
extends FilePacket

Author:
Mark Bednarczyk, Sly Technologies, Inc.

Nested Class Summary
 
Nested classes/interfaces inherited from interface org.jnetstream.packet.Packet
Packet.Property
 
Method Summary
 void setTimestampMicros(int micros)
          Sets the capture timestamp fraction of a second in micros within the Pcap packet record header.
 void setTimestampSeconds(long seconds)
          Sets the capture timestamp seconds field within the Pcap packet record header.
 
Methods inherited from interface org.jnetstream.capture.FilePacket
getPositionGlobal, getPositionLocal, getPositionRegional
 
Methods inherited from interface org.jnetstream.capture.CapturePacket
getCaptureDevice, getIncludedLength, getOriginalLength
 
Methods inherited from interface org.jnetstream.packet.Packet
format, getAllHeaders, getBuffer, getData, getHeader, getHeader, getHeaderCount, getProperty, getTimestampNanos, getTimestampSeconds, hasCompleteHeader, hasCompleteHeader, hasHeader, hasHeader, isTruncated, iterator
 

Method Detail

setTimestampSeconds

void setTimestampSeconds(long seconds)
                         throws java.io.IOException
Sets the capture timestamp seconds field within the Pcap packet record header.

Parameters:
seconds - timestamp in seconds
Throws:
java.io.IOException - any IO errros

setTimestampMicros

void setTimestampMicros(int micros)
                        throws java.io.IOException
Sets the capture timestamp fraction of a second in micros within the Pcap packet record header. The number of microseconds fraction at the time the packet was captured.

Parameters:
micros - fraction of a second in microsecond with valid value of 0 and 999,999 inclusive.
Throws:
java.io.IOException - any IO errors