import java.util.ArrayList;
import java.util.List;
-import org.opendaylight.transportpce.pce.networkanalyzer.PceNode;
+import org.opendaylight.transportpce.pce.networkanalyzer.PceOpticalNode;
import org.opendaylight.yang.gen.v1.http.org.transportpce.b.c._interface.routing.constraints.rev171017.RoutingConstraintsSp;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
private RoutingConstraintsSp.PceMetric pceMetrics = RoutingConstraintsSp.PceMetric.HopCount;
private Long maxLatency = (long) -1;
- /////////////// EXCLUDE ///////////////////
+ // Structure related to EXCLUDE constraints
// Nodes/CLLI/SRLG lists might consist of two types of elements : (1)from diversity constraints (2)from exclude list
// e.g.: nodesToExclude - topo-level nodes IDs - comes from diversity constraints
// : supNodesToExclude - supporting nodes IDs - comes from exclude list
private List<String> clliToExclude = new ArrayList<String>();
private List<String> clliNodesToExclude = new ArrayList<String>();
- private List<String> nodesToInclude = new ArrayList<String>();
- private List<PceNode> pceNodesToInclude = new ArrayList<PceNode>();
-
- public static final Long CONST_OSNR = 1L;
- private double maxOSNR = (CONST_OSNR / (Math.pow(10, (24 / 10.0))));
- /**.
- * /////////////// INCLUDE CONSTRAINTS.///////////////////
- */
+ ///Structures related to INCLUDE constraints
+ private List<String> nodesToInclude = new ArrayList<String>();
+ private List<PceOpticalNode> pceNodesToInclude = new ArrayList<PceOpticalNode>();
private List<ResourcePair> listToInclude = new ArrayList<ResourcePair>();
+
private List<String> srlgNames = new ArrayList<String>();
public enum ResourceType {
nodesToInclude.addAll(nodes);
}
- public List<PceNode> getIncludePceNodes() {
+ public List<PceOpticalNode> getIncludePceNodes() {
LOG.debug("in Pceconstraints getIncludePceNodes size = {}", pceNodesToInclude.size());
return pceNodesToInclude;
}
- public void setIncludePceNode(PceNode node) {
+ public void setIncludePceNode(PceOpticalNode node) {
LOG.info("in Pceconstraints setIncludePceNode new node = {}", node.toString());
this.pceNodesToInclude.add(node);
}
- public Double getMaxOSNR() {
- LOG.debug("in Pceconstraints getMaxOSNR = {}", maxOSNR);
- return maxOSNR;
- }
-
public class ResourcePair {
public ResourcePair(ResourceType type, String name) {
super();