|
INET Framework for OMNeT++/OMNEST
|
This class provides efficient general purpose packet dissection. More...
#include <PacketDissector.h>
Classes | |
| class | ChunkBuilder |
| class | ICallback |
| class | PduTreeBuilder |
| class | ProtocolDataUnit |
| class | ProtocolDissectorCallback |
Public Member Functions | |
| PacketDissector (const ProtocolDissectorRegistry &protocolDissectorRegistry, ICallback &callback) | |
| void | dissectPacket (Packet *packet) const |
| Dissects the given packet according to the attached PacketProtocolTag. More... | |
| void | dissectPacket (Packet *packet, const Protocol *protocol, b extraFrontOffset=b(0), b extraBackOffset=b(0)) const |
| Dissects the given packet of the provided protocol. More... | |
Protected Member Functions | |
| void | doDissectPacket (Packet *packet, const Protocol *protocol) const |
Protected Attributes | |
| const ProtocolDissectorRegistry & | protocolDissectorRegistry |
| ICallback & | callback |
This class provides efficient general purpose packet dissection.
Packet dissection may be useful for printing packet details, filter packets, finding information in a packet deep down.
The supported protocols are provided by a ProtocolDissectorRegistry. The packet dissection algorithm calls the visitChunk() method of the provided PacketDissector::ICallback for each protocol specific chunk found in the packet. The chunks are passed to the method in the order they appear in the packet from left to right using their most specific protocol dependent form.
| inet::PacketDissector::PacketDissector | ( | const ProtocolDissectorRegistry & | protocolDissectorRegistry, |
| ICallback & | callback | ||
| ) |
| void inet::PacketDissector::dissectPacket | ( | Packet * | packet | ) | const |
Dissects the given packet according to the attached PacketProtocolTag.
Referenced by inet::Packet::getDissection(), inet::BehaviorAggregateClassifier::PacketDissectorCallback::matches(), inet::MultiFieldClassifier::PacketDissectorCallback::matches(), inet::PacketFilter::matches(), inet::PacketPrinter::printPacket(), and inet::PacketDeserializer::processPacket().
| void inet::PacketDissector::dissectPacket | ( | Packet * | packet, |
| const Protocol * | protocol, | ||
| b | extraFrontOffset = b(0), |
||
| b | extraBackOffset = b(0) |
||
| ) | const |
Dissects the given packet of the provided protocol.
The packet dissection algorithm calls the visitChunk() method of the provided callback for each protocol specific chunk found in the packet.
|
protected |
Referenced by dissectPacket().
|
protected |
Referenced by doDissectPacket().
|
protected |
Referenced by doDissectPacket().