public class PPPoED extends BasePacket
| Modifier and Type | Class and Description |
|---|---|
static class |
PPPoED.Type |
| Modifier and Type | Field and Description |
|---|---|
protected byte |
code |
protected short |
payloadLength |
static byte |
PPPOED_CODE_PADI |
static byte |
PPPOED_CODE_PADO |
static byte |
PPPOED_CODE_PADR |
static byte |
PPPOED_CODE_PADS |
static byte |
PPPOED_CODE_PADT |
protected short |
sessionId |
protected java.util.List<PPPoEDTag> |
tags |
protected byte |
type |
protected byte |
version |
parent, payload| Constructor and Description |
|---|
PPPoED() |
| Modifier and Type | Method and Description |
|---|---|
static Deserializer<PPPoED> |
deserializer()
Deserializer for PPPoED packets.
|
byte |
getCode() |
short |
getPayloadLength() |
short |
getSessionId() |
PPPoEDTag |
getTag(short tagType)
Gets a tag from the packet.
|
java.util.ArrayList<PPPoEDTag> |
getTagList(short tagType)
Gets a list of tags from the packet.
|
java.util.List<PPPoEDTag> |
getTags() |
byte |
getType() |
byte |
getVersion() |
byte[] |
serialize()
Sets all payloads parent packet if applicable, then serializes this
packet and all payloads.
|
void |
setCode(byte code) |
void |
setPayloadLength(short payloadLength) |
void |
setSessionId(short sessionId) |
PPPoEDTag |
setTag(short tagType,
byte[] value)
Sets a tag in the packet.
|
void |
setTags(java.util.List<PPPoEDTag> tags) |
void |
setType(byte type) |
void |
setVersion(byte version) |
java.lang.String |
toString() |
clone, equals, getParent, getPayload, hashCode, resetChecksum, setParent, setPayloadprotected byte version
protected byte type
protected byte code
protected short sessionId
protected short payloadLength
protected java.util.List<PPPoEDTag> tags
public static final byte PPPOED_CODE_PADI
public static final byte PPPOED_CODE_PADO
public static final byte PPPOED_CODE_PADR
public static final byte PPPOED_CODE_PADS
public static final byte PPPOED_CODE_PADT
public byte getVersion()
public void setVersion(byte version)
public byte getType()
public void setType(byte type)
public byte getCode()
public void setCode(byte code)
public short getSessionId()
public void setSessionId(short sessionId)
public short getPayloadLength()
public void setPayloadLength(short payloadLength)
public java.util.List<PPPoEDTag> getTags()
public void setTags(java.util.List<PPPoEDTag> tags)
public java.util.ArrayList<PPPoEDTag> getTagList(short tagType)
tagType - the type field of the required tagspublic PPPoEDTag getTag(short tagType)
tagType - the type field of the required tagpublic PPPoEDTag setTag(short tagType, byte[] value)
tagType - the type field of the tag to setvalue - value to be setpublic static Deserializer<PPPoED> deserializer()
public byte[] serialize()
IPacketpublic java.lang.String toString()
toString in class java.lang.Object