C# Class SharpPcap.Packets.EthernetPacket

Inheritance: Packet, EthernetFields
Afficher le fichier Open project: Zepheus/Fiesta_Utils Class Usage Examples

Protected Properties

Свойство Type Description
_ethOffset int
_timeval SharpPcap.Packets.Util.Timeval

Méthodes publiques

Méthode Description
EthernetPacket ( int lLen, byte bytes ) : System

Construct a new ethernet packet.

For the purpose of jpcap, when the type of ethernet packet is recognized as a protocol for which a class exists network library, then a more specific class like IPPacket or ARPPacket is instantiated. The subclass can always be cast into a more generic form.

EthernetPacket ( int lLen, byte bytes, Timeval tv ) : System

Construct a new ethernet packet, including the capture time.

OnOffsetChanged ( ) : void

should be overriden by upper classes

ToColoredString ( bool colored ) : System.String

Generate string with contents describing this ethernet packet.

ToColoredVerboseString ( bool colored ) : System.String

Convert this IP packet to a more verbose string.

ToString ( ) : System.String

Convert this ethernet packet to a readable string.

extractProtocol ( byte packetBytes ) : int

Extract the protocol type field from packet data.

The type field indicates what type of data is contained in the packet's data block.

Method Details

EthernetPacket() public méthode

Construct a new ethernet packet.

For the purpose of jpcap, when the type of ethernet packet is recognized as a protocol for which a class exists network library, then a more specific class like IPPacket or ARPPacket is instantiated. The subclass can always be cast into a more generic form.

public EthernetPacket ( int lLen, byte bytes ) : System
lLen int
bytes byte
Résultat System

EthernetPacket() public méthode

Construct a new ethernet packet, including the capture time.
public EthernetPacket ( int lLen, byte bytes, Timeval tv ) : System
lLen int
bytes byte
tv SharpPcap.Packets.Util.Timeval
Résultat System

OnOffsetChanged() public méthode

should be overriden by upper classes
public OnOffsetChanged ( ) : void
Résultat void

ToColoredString() public méthode

Generate string with contents describing this ethernet packet.
public ToColoredString ( bool colored ) : System.String
colored bool whether or not the string should contain ansi /// color escape sequences. ///
Résultat System.String

ToColoredVerboseString() public méthode

Convert this IP packet to a more verbose string.
public ToColoredVerboseString ( bool colored ) : System.String
colored bool
Résultat System.String

ToString() public méthode

Convert this ethernet packet to a readable string.
public ToString ( ) : System.String
Résultat System.String

extractProtocol() public static méthode

Extract the protocol type field from packet data.

The type field indicates what type of data is contained in the packet's data block.

public static extractProtocol ( byte packetBytes ) : int
packetBytes byte packet bytes. ///
Résultat int

Property Details

_ethOffset protected_oe property

protected int _ethOffset
Résultat int

_timeval protected_oe property

protected Timeval,SharpPcap.Packets.Util _timeval
Résultat SharpPcap.Packets.Util.Timeval