1.1 - Getting Around

Let briefly go over all of the packages in jNetPcap SDK and what they contain:

  +-> jnetcap - this is the main libpcap wrapper package. It contains
      +         all of the API for accessing libpcap functionality.
      |         These classes and methods do very little of their own
      |         logic and simply pass your requests over to native
      |         libpcap which handles those the requested actions.
      +-> winpcap - extension to libpcap wrapper that provides WinPcap 
      |          functions. This is operating system dependent package
      |          and you must use WinPcap.isSupported() call before
      |          using any classes and methods in this package.
      +-> nio - native IO and memory classes. This package defines
      |         memory management classes that allocate native memory,
      |         peer native structures and functions to java classes. 
      |         This is also where the very important JBuffer class resides.
      +-> util - various utility classes. This is where you will find
      |          logging helpers, JConfig class which manages configurations
      |          through property files and address resolvers. 
      +-> protocol - a library of supported CORE protocol headers.
      |              This is where you will find Ip4, Tcp, Udp, Ethernet
      |              and a host of other header definitions, ready for you
      |              to use.
      +-> packet - packet decoding framework. This package defines important 
          |      components of the decoder. JScanner, PcapPacket, and the very
          |      important baseclass JHeader. JScanner decodes packets
          |      and stores the packet state information in native structures.
          |      PcapPacket class reads this state information and can
          |      peer (or reference via native memory) header objects. 
          |      All header classes subclass JHeader class.
           +-> format - packet formatters. They dump the decoded packet 
          |      content in textual form. You can use TextFormatter or XmlFormatter.
          +-> structure - this package is utilized by protocol builders. 
          |      It contains building blocks of decoded packet that
          |      formatters use. This is a package you will not normally
          |      have to deal with.
          +-> annotate - annotation interfaces used in writting protocol headers.
                 Unless you are writting a new protocol header definiton
                 you will not need access any of these annotations.