Path Computation Algorithms
[bgpcep.git] / algo / algo-api / src / main / java / org / opendaylight / algo / PathComputationAlgorithm.java
1 /*
2  * Copyright (c) 2020 Orange. All rights reserved.
3  *
4  * This program and the accompanying materials are made available under the
5  * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6  * and is available at http://www.eclipse.org/legal/epl-v10.html
7  */
8
9 package org.opendaylight.algo;
10
11 import org.eclipse.jdt.annotation.NonNull;
12 import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.graph.rev191125.graph.topology.graph.VertexKey;
13 import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.path.computation.rev200120.ConstrainedPath;
14 import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.path.computation.rev200120.PathConstraints;
15
16 /**
17  * This class provides entry for various Path Computation Algorithms.
18  *
19  * @author Olivier Dugeon
20  *
21  */
22 public interface PathComputationAlgorithm {
23
24     /**
25      * Compute Point to Point Path from source to destination taking into account constraints.
26      *
27      * @param source      Source Vertex Key
28      * @param destination Destination Vertex Key
29      * @param constraints Constraints (Metric, TE Metric, Delay, Jitter, Loss, Bandwidth)
30      *
31      * @return A Path that meet constraints or empty path otherwise. ConstrainedPath.Status indicates the result of
32      *         the path computation (Completed or Failed)
33      */
34     @NonNull ConstrainedPath computeP2pPath(VertexKey source, VertexKey destination, PathConstraints constraints);
35 }