org.jnetpcap.packet.analysis
Class AbstractSequencer

java.lang.Object
  extended by org.jnetpcap.packet.analysis.AbstractAnalyzer
      extended by org.jnetpcap.packet.analysis.AbstractSequencer
All Implemented Interfaces:
FragmentSequencer, JAnalyzer
Direct Known Subclasses:
Ip4Sequencer, TcpSequencer

public abstract class AbstractSequencer
extends AbstractAnalyzer
implements FragmentSequencer

Author:
Mark Bednarczyk, Sly Technologies, Inc.

Field Summary
protected  java.util.Map<java.lang.Integer,FragmentSequence> fragmentation
           
protected  AnalyzerSupport<FragmentSequenceEvent> fragSupport
           
 
Fields inherited from interface org.jnetpcap.packet.analysis.FragmentSequencer
DEFAULT_FRAGMENT_TIMEOUT, reassembly
 
Constructor Summary
AbstractSequencer()
           
AbstractSequencer(int priority)
           
AbstractSequencer(int priority, JAnalyzer parent)
           
 
Method Summary
 boolean addFragmentationListener(AnalyzerListener<FragmentSequenceEvent> listener)
           
 long getProcessingTime()
           
protected  FragmentSequence getSequence(int hash, boolean create)
           
 boolean removeFragmentationListener(AnalyzerListener<FragmentSequenceEvent> listener)
           
protected  void removeSequence(int hash)
           
protected  void setProcessingTime(JPacket packet)
           
 void timeout(FragmentSequence analysis)
          Signal to analyzer that this fragment sequence has expired
 
Methods inherited from class org.jnetpcap.packet.analysis.AbstractAnalyzer
consumePacket, getInQueue, getOutQueue, getPriority, getTimeoutQueue, hold, processHeaders, processHeaders, processPacket, release, setParent
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.jnetpcap.packet.analysis.FragmentSequencer
generateInfo
 
Methods inherited from interface org.jnetpcap.packet.analysis.JAnalyzer
consumePacket, getInQueue, getOutQueue, getPriority, getTimeoutQueue, hold, processHeaders, processHeaders, processPacket, release, setParent
 

Field Detail

fragmentation

protected final java.util.Map<java.lang.Integer,FragmentSequence> fragmentation

fragSupport

protected final AnalyzerSupport<FragmentSequenceEvent> fragSupport
Constructor Detail

AbstractSequencer

public AbstractSequencer()

AbstractSequencer

public AbstractSequencer(int priority)
Parameters:
priority -

AbstractSequencer

public AbstractSequencer(int priority,
                         JAnalyzer parent)
Parameters:
priority -
parent -
Method Detail

getSequence

protected FragmentSequence getSequence(int hash,
                                       boolean create)

removeSequence

protected void removeSequence(int hash)

addFragmentationListener

public boolean addFragmentationListener(AnalyzerListener<FragmentSequenceEvent> listener)

removeFragmentationListener

public boolean removeFragmentationListener(AnalyzerListener<FragmentSequenceEvent> listener)

timeout

public void timeout(FragmentSequence analysis)
Description copied from interface: FragmentSequencer
Signal to analyzer that this fragment sequence has expired

Specified by:
timeout in interface FragmentSequencer
Parameters:
analysis - sequence which expired

setProcessingTime

protected void setProcessingTime(JPacket packet)

getProcessingTime

public long getProcessingTime()
Specified by:
getProcessingTime in interface JAnalyzer
Overrides:
getProcessingTime in class AbstractAnalyzer