public class BgpPathAttributes extends Object
| Modifier and Type | Field and Description |
|---|---|
static int |
EXTENDED_COMMUNITY_TYPE |
static int |
LINK_STATE_ATTRIBUTE_TYPE |
protected static org.slf4j.Logger |
log |
static int |
MPREACHNLRI_TYPE |
static int |
MPUNREACHNLRI_TYPE |
| Constructor and Description |
|---|
BgpPathAttributes()
Initialize parameter.
|
BgpPathAttributes(List<BgpValueType> pathAttribute)
Constructor to initialize parameters for BGP path attributes.
|
| Modifier and Type | Method and Description |
|---|---|
static void |
checkMandatoryAttr(boolean isOrigin,
boolean isAsPath,
boolean isNextHop,
boolean isMpReach,
boolean isMpUnReach)
Checks mandatory attributes are presents, if not present throws exception.
|
List<BgpValueType> |
pathAttributes()
Returns list of path attributes.
|
static BgpPathAttributes |
read(org.jboss.netty.buffer.ChannelBuffer cb)
Reads from channelBuffer and parses BGP path attributes.
|
String |
toString() |
int |
write(org.jboss.netty.buffer.ChannelBuffer cb)
Write path attributes to channelBuffer.
|
protected static final org.slf4j.Logger log
public static final int LINK_STATE_ATTRIBUTE_TYPE
public static final int MPREACHNLRI_TYPE
public static final int MPUNREACHNLRI_TYPE
public static final int EXTENDED_COMMUNITY_TYPE
public BgpPathAttributes()
public BgpPathAttributes(List<BgpValueType> pathAttribute)
pathAttribute - list of path attributespublic List<BgpValueType> pathAttributes()
public static BgpPathAttributes read(org.jboss.netty.buffer.ChannelBuffer cb) throws BgpParseException
cb - channelBufferBgpParseException - while parsing BGP path attributespublic int write(org.jboss.netty.buffer.ChannelBuffer cb)
throws BgpParseException
cb - channelBufferBgpParseException - while parsing BGP path attributespublic static void checkMandatoryAttr(boolean isOrigin,
boolean isAsPath,
boolean isNextHop,
boolean isMpReach,
boolean isMpUnReach)
throws BgpParseException
isOrigin - say whether origin attribute is presentisAsPath - say whether aspath attribute is presentisNextHop - say whether nexthop attribute is presentisMpReach - say whether mpreach attribute is presentisMpUnReach - say whether mpunreach attribute is presentBgpParseException - if mandatory path attribute is not presentCopyright © 2016. All rights reserved.