use of org.opendaylight.protocol.bgp.inet.codec.Ipv6BgpPrefixSidParser in project bgpcep by opendaylight.
the class BGPActivator method startImpl.
@Override
protected List<AutoCloseable> startImpl(final BGPExtensionProviderContext context) {
final List<AutoCloseable> regs = new ArrayList<>(6);
final Ipv4NextHopParserSerializer ipv4NextHopParser = new Ipv4NextHopParserSerializer();
final Ipv4NlriParser ipv4Codec = new Ipv4NlriParser();
regs.add(context.registerNlriParser(Ipv4AddressFamily.class, UnicastSubsequentAddressFamily.class, ipv4Codec, ipv4NextHopParser, Ipv4NextHopCase.class, Ipv6NextHopCase.class));
regs.add(context.registerNlriSerializer(Ipv4Routes.class, ipv4Codec));
final Ipv6NextHopParserSerializer ipv6NextHopParser = new Ipv6NextHopParserSerializer();
final Ipv6NlriParser ipv6Codec = new Ipv6NlriParser();
regs.add(context.registerNlriParser(Ipv6AddressFamily.class, UnicastSubsequentAddressFamily.class, ipv6Codec, ipv6NextHopParser, Ipv4NextHopCase.class, Ipv6NextHopCase.class));
regs.add(context.registerNlriSerializer(Ipv6Routes.class, ipv6Codec));
final Ipv6BgpPrefixSidParser tlvHandler = new Ipv6BgpPrefixSidParser();
regs.add(context.registerBgpPrefixSidTlvParser(tlvHandler.getType(), tlvHandler));
regs.add(context.registerBgpPrefixSidTlvSerializer(Ipv6SidTlv.class, tlvHandler));
return regs;
}
Aggregations