Enum bgpkit_parser::AttributeFlagsBit
source · pub enum AttributeFlagsBit {
OptionalBit,
TransitiveBit,
PartialBit,
ExtendedLengthBit,
}
Expand description
The high-order bit (bit 0) of the Attribute Flags octet is the Optional bit. It defines whether the attribute is optional (if set to 1) or well-known (if set to 0).
The second high-order bit (bit 1) of the Attribute Flags octet is the Transitive bit. It defines whether an optional attribute is transitive (if set to 1) or non-transitive (if set to 0).
For well-known attributes, the Transitive bit MUST be set to 1. (See Section 5 for a discussion of transitive attributes.)
The third high-order bit (bit 2) of the Attribute Flags octet is the Partial bit. It defines whether the information contained in the optional transitive attribute is partial (if set to 1) or complete (if set to 0). For well-known attributes and for optional non-transitive attributes, the Partial bit MUST be set to 0.
The fourth high-order bit (bit 3) of the Attribute Flags octet is the Extended Length bit. It defines whether the Attribute Length is one octet (if set to 0) or two octets (if set to 1).
Variants§
OptionalBit
128 = 0b10000000
TransitiveBit
64 = 0b01000000
PartialBit
32 = 0b00100000
ExtendedLengthBit
16 = 0b00010000