Search in sources :

Example 11 with Edge

use of org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.graph.rev191125.graph.topology.graph.Edge in project bgpcep by opendaylight.

the class LinkstateGraphBuilder method removeEdge.

private void removeEdge(final LinkCase linkCase) {
    /* Get Source and Destination Connected Vertex */
    if (linkCase.getLinkDescriptors() == null) {
        LOG.warn("Missing Link descriptor in link {}, skipping it", linkCase);
        return;
    }
    EdgeKey edgeKey = new EdgeKey(getEdgeId(linkCase));
    if (edgeKey == null || edgeKey.getEdgeId() == Uint64.ZERO) {
        LOG.warn("Unable to get the Edge Key from link {}, skipping it", linkCase);
        return;
    }
    LOG.info("Deleted Edge {} from TED[{}]", edgeKey, cgraph);
    cgraph.deleteEdge(edgeKey);
}
Also used : EdgeKey(org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.graph.rev191125.graph.topology.graph.EdgeKey)

Aggregations

ConnectedEdge (org.opendaylight.graph.ConnectedEdge)6 Edge (org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.graph.rev191125.graph.topology.graph.Edge)3 ConstrainedPathBuilder (org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.path.computation.rev200120.ConstrainedPathBuilder)3 ArrayList (java.util.ArrayList)2 IpPrefix (org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.IpPrefix)2 Delay (org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.graph.rev191125.Delay)2 UnreservedBandwidth (org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.graph.rev191125.edge.attributes.UnreservedBandwidth)2 Prefix (org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.graph.rev191125.graph.topology.graph.Prefix)2 Uint64 (org.opendaylight.yangtools.yang.common.Uint64)2 ConnectedVertex (org.opendaylight.graph.ConnectedVertex)1 IpAddress (org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.IpAddress)1 Ipv4Prefix (org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv4Prefix)1 Ipv6Prefix (org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Prefix)1 SrAdjIds (org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.linkstate.rev200120.linkstate.attribute.SrAdjIds)1 LinkDescriptors (org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.linkstate.rev200120.linkstate.object.type.link._case.LinkDescriptors)1 LinkAttributes (org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.linkstate.rev200120.linkstate.path.attribute.link.state.attribute.link.attributes._case.LinkAttributes)1 IsisAdjFlags (org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.segment.routing.ext.rev200120.adj.flags.flags.isis.adj.flags._case.IsisAdjFlags)1 OspfAdjFlags (org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.segment.routing.ext.rev200120.adj.flags.flags.ospf.adj.flags._case.OspfAdjFlags)1 LocalLabelCase (org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.segment.routing.ext.rev200120.sid.label.index.sid.label.index.LocalLabelCase)1 Loss (org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.graph.rev191125.Loss)1