パッケージ org.pcap4j.core
クラス BpfProgram
- java.lang.Object
-
- org.pcap4j.core.BpfProgram
-
public final class BpfProgram extends Object
- 導入されたバージョン:
- pcap4j 0.9.16
- 作成者:
- Kaito Yamada
-
-
ネストされたクラスの概要
ネストされたクラス 修飾子とタイプ クラス 説明 static class
BpfProgram.BpfCompileMode
-
メソッドの概要
すべてのメソッド インスタンス・メソッド concreteメソッド 修飾子とタイプ メソッド 説明 boolean
applyFilter(byte[] packet)
Apply the filter on a given packet.boolean
applyFilter(byte[] packet, int orgPacketLen, int packetLen)
Apply the filter on a given packet.boolean
applyFilter(Packet packet)
Apply the filter on a given packet.void
free()
String
getExpression()
boolean
isFreed()
-
-
-
メソッドの詳細
-
getExpression
public String getExpression()
- 戻り値:
- expression
-
applyFilter
public boolean applyFilter(Packet packet)
Apply the filter on a given packet. Return true if the packet given passes the filter that is built from this program.- パラメータ:
packet
- the packet to apply the filter on- 戻り値:
- true if this program is not freed and the packet passes the filter; false otherwise.
-
applyFilter
public boolean applyFilter(byte[] packet)
Apply the filter on a given packet. Return true if the packet given passes the filter that is built from this program.- パラメータ:
packet
- the packet to apply the filter on- 戻り値:
- true if this program is not freed and the packet passes the filter; false otherwise.
-
applyFilter
public boolean applyFilter(byte[] packet, int orgPacketLen, int packetLen)
Apply the filter on a given packet. Return true if the packet given passes the filter that is built from this program.- パラメータ:
packet
- a byte array including the packet to apply the filter onorgPacketLen
- the length of the original packetpacketLen
- the length of the packet present- 戻り値:
- true if this program is not freed and the packet passes the filter; false otherwise.
-
isFreed
public boolean isFreed()
- 戻り値:
- true if the bpf_program represented by this object is freed; false otherwise.
-
free
public void free()
-
-