public class RIPngEntry extends BasePacket
Modifier and Type | Field and Description |
---|---|
static int |
ENTRY_LEN |
static byte |
INFINITY_METRIC |
protected int |
metric |
static int |
NEXTHOP_METRIC |
static int |
OPT_CODE_LEN |
protected byte[] |
prefix |
protected int |
prefixLen |
protected short |
routeTag |
parent, payload
Constructor and Description |
---|
RIPngEntry() |
Modifier and Type | Method and Description |
---|---|
static Deserializer<RIPngEntry> |
deserializer()
Deserializer function for RIPng entry.
|
boolean |
equals(Object obj) |
int |
getMetric() |
byte[] |
getPrefix() |
int |
getPrefixLen() |
short |
getRouteTag() |
int |
hashCode() |
byte[] |
serialize()
Sets all payloads parent packet if applicable, then serializes this
packet and all payloads.
|
RIPngEntry |
setMetric(int metric) |
RIPngEntry |
setPrefix(byte[] prefix) |
RIPngEntry |
setPrefixLen(int prefixlen) |
RIPngEntry |
setRouteTag(short routetag) |
String |
toString() |
clone, getParent, getPayload, resetChecksum, setParent, setPayload
public static final int OPT_CODE_LEN
public static final int ENTRY_LEN
public static final byte INFINITY_METRIC
public static final int NEXTHOP_METRIC
protected byte[] prefix
protected short routeTag
protected int prefixLen
protected int metric
public byte[] serialize()
IPacket
public static Deserializer<RIPngEntry> deserializer()
public int hashCode()
hashCode
in class BasePacket
public boolean equals(Object obj)
equals
in class BasePacket
public byte[] getPrefix()
public RIPngEntry setPrefix(byte[] prefix)
prefix
- the IPv6 prefix to setpublic short getRouteTag()
public RIPngEntry setRouteTag(short routetag)
routetag
- the route tag to setpublic int getPrefixLen()
public RIPngEntry setPrefixLen(int prefixlen)
prefixlen
- the prefix length to setpublic int getMetric()
public RIPngEntry setMetric(int metric)
metric
- the route metric to set