整理SRv6Router代码,修bug,增加SRHInsert虚链路

This commit is contained in:
2026-08-31 19:07:53 +08:00
parent 52f44335e4
commit 2c111770b3
17 changed files with 287 additions and 190 deletions
@@ -7,6 +7,7 @@ public class RouteItem implements Comparable<RouteItem>,Cloneable{
public static final String DIRECT="Direct";
public static final String SRv6_ENDSID="SRv6 ENDSID";
public static final String SRv6_ENDXSID="SRv6 ENDXSID";
public static final String KLALB_SRv6 = "KLALB_SRv6";
private IPv6AddressGroup destination;
private IPv6Address nexthop;
@@ -39,7 +40,7 @@ public class RouteItem implements Comparable<RouteItem>,Cloneable{
public RouteItem(IPv6AddressGroup destination, IPv6Address nexthop, IPv6NetworkLink destlink, String proto, int pre,
long cost,String flag) {
super();
this.destination = destination;
this.destination = destination.toNetworkRoute();
this.nexthop = nexthop;
this.destlink = destlink;
this.proto = proto;
@@ -50,7 +51,7 @@ public class RouteItem implements Comparable<RouteItem>,Cloneable{
public RouteItem(IPv6AddressGroup destination, IPv6Address nexthop, IPv6NetworkLink destlink, String proto, int pre,
long cost,Supplier<Long> costSupplier,String flag) {
super();
this.destination = destination;
this.destination = destination.toNetworkRoute();
this.nexthop = nexthop;
this.destlink = destlink;
this.proto = proto;