|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjava.io.InputStream
com.voytechs.jnetstream.io.ProtocolDataInputStream
com.voytechs.jnetstream.io.PacketInputStream
com.voytechs.jnetstream.io.SnoopInputStream
public class SnoopInputStream
For structure of the Snoop file see RFC1761 http://www.faqs.org/rfcs/rfc1761.html
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class com.voytechs.jnetstream.io.PacketInputStream |
|---|
PacketInputStream.BufferedHeader |
| Field Summary |
|---|
| Fields inherited from class com.voytechs.jnetstream.io.PacketInputStream |
|---|
captureDeviceArch, captureDeviceFilename, captureDeviceIp, captureDeviceOS, captureLive, debugHeaders, fileHeader, linkType, packetCaptureTimestamp, packetEnd, packetLength, packetSnaplen, packetStart, recordEnd, recordHeader, recordLength, recordStart, stackIn |
| Fields inherited from class com.voytechs.jnetstream.io.ProtocolDataInputStream |
|---|
bitsLeft, in |
| Constructor Summary | |
|---|---|
SnoopInputStream(java.io.InputStream snoopFileFormatInputStream)
|
|
SnoopInputStream(java.lang.String filename)
Opens up the given file and starts processing the data. |
|
| Method Summary | |
|---|---|
byte[] |
getSnoopMagicNumber()
Returns the magic number found at the beginning of the SNOOP file. |
long |
getSnoopMajorVer()
Returns the major version number of the SNOOP file. |
protected void |
initPacketStream()
Since we know we are dealing with a Snoop-file formatted stream (i.e. |
protected void |
initRecordHeader()
Read pre-packet header from stream. |
long |
snoopLinktype()
The link type of the first header in the packet. |
long |
snoopPacketCaptureNanos()
Number of naono seconds found in the raw data file. |
long |
snoopPacketCaptureSecs()
Number of raw number of the capture file. |
long |
snoopSnaplen()
Retuns the SNAP len of the capture file. |
java.lang.String |
toString()
|
| Methods inherited from class com.voytechs.jnetstream.io.ProtocolDataInputStream |
|---|
readBits, readBitsLong, readBoolean, readByte, readerUnsignedLongLittleEndian, readFromPacket, readFromPacket, readInt, readIntLittleEndian, readLong, readLongLittleEndian, readShort, readShortLittleEndian, readUnsignedByte, readUnsignedInt, readUnsignedIntLittleEndian, readUnsignedLong, readUnsignedShort, readUnsignedShortLittleEndian, reThrow |
| Methods inherited from class java.io.InputStream |
|---|
available, close, mark, markSupported, read, read, reset |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public SnoopInputStream(java.io.InputStream snoopFileFormatInputStream)
throws java.io.IOException,
EOPacketStream,
StreamFormatException
-
java.io.IOException
EOPacketStream
StreamFormatException
public SnoopInputStream(java.lang.String filename)
throws java.io.FileNotFoundException,
java.io.IOException,
EOPacketStream,
StreamFormatException
filename - Filename of the file in SNOOP fileformat to open.
java.io.FileNotFoundException
java.io.IOException
EOPacketStream
StreamFormatException| Method Detail |
|---|
protected void initPacketStream()
throws java.io.IOException,
EOPacketStream,
StreamFormatException
initPacketStream in class PacketInputStreamjava.io.IOException
EOPacketStream
StreamFormatException
protected void initRecordHeader()
throws java.io.IOException,
EOPacketStream,
StreamFormatException
initRecordHeader in class PacketInputStreamjava.io.IOException
EOPacketStream
StreamFormatExceptionpublic java.lang.String toString()
toString in class java.lang.Objectpublic byte[] getSnoopMagicNumber()
public long getSnoopMajorVer()
public long snoopSnaplen()
public long snoopLinktype()
public long snoopPacketCaptureSecs()
public long snoopPacketCaptureNanos()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||