Code Review
/
transportpce.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
Migration to TAPI 2.4 Step1
[transportpce.git]
/
tapi
/
src
/
main
/
java
/
org
/
opendaylight
/
transportpce
/
tapi
/
validation
/
checks
/
TopoConstraintCheck.java
diff --git
a/tapi/src/main/java/org/opendaylight/transportpce/tapi/validation/checks/TopoConstraintCheck.java
b/tapi/src/main/java/org/opendaylight/transportpce/tapi/validation/checks/TopoConstraintCheck.java
index 8a07469702b91dc9f2f8531e02c8b314dd7bced2..7e94a539193b305bdd15d07b04b90963254c2abd 100644
(file)
--- a/
tapi/src/main/java/org/opendaylight/transportpce/tapi/validation/checks/TopoConstraintCheck.java
+++ b/
tapi/src/main/java/org/opendaylight/transportpce/tapi/validation/checks/TopoConstraintCheck.java
@@
-8,7
+8,7
@@
package org.opendaylight.transportpce.tapi.validation.checks;
import org.opendaylight.transportpce.servicehandler.validation.checks.ComplianceCheckResult;
package org.opendaylight.transportpce.tapi.validation.checks;
import org.opendaylight.transportpce.servicehandler.validation.checks.ComplianceCheckResult;
-import org.opendaylight.yang.gen.v1.urn.onf.otcc.yang.tapi.connectivity.rev
181210
.create.connectivity.service.input.TopologyConstraint;
+import org.opendaylight.yang.gen.v1.urn.onf.otcc.yang.tapi.connectivity.rev
221121
.create.connectivity.service.input.TopologyConstraint;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@
-23,14
+23,14
@@
public final class TopoConstraintCheck {
return ((value != null) && (!value.isEmpty()));
}
return ((value != null) && (!value.isEmpty()));
}
- public static ComplianceCheckResult check(TopologyConstraint t
c
) {
+ public static ComplianceCheckResult check(TopologyConstraint t
opoConstraint
) {
boolean result = true;
String message = "";
boolean result = true;
String message = "";
- LOG.info("tc = {}", t
c
);
- if (checkNull(t
c
)) {
+ LOG.info("tc = {}", t
opoConstraint
);
+ if (checkNull(t
opoConstraint
)) {
LOG.info("tc is null");
message = "Topology constraints are not managet yet";
LOG.info("tc is null");
message = "Topology constraints are not managet yet";
- } else if (checkEmpty(t
c
)) {
+ } else if (checkEmpty(t
opoConstraint
)) {
result = false;
message = "Topology constraints are not managet yet";
}
result = false;
message = "Topology constraints are not managet yet";
}
@@
-42,7
+42,7
@@
public final class TopoConstraintCheck {
if (tc == null) {
return true;
}
if (tc == null) {
return true;
}
- if (tc.get
Avoid
Topology() == null) {
+ if (tc.get
Exclude
Topology() == null) {
return true;
}
if (tc.getExcludeLink() == null) {
return true;
}
if (tc.getExcludeLink() == null) {
@@
-75,7
+75,7
@@
public final class TopoConstraintCheck {
if (tc == null) {
return true;
}
if (tc == null) {
return true;
}
- if (tc.get
AvoidTopology() != null && tc.getAvoid
Topology().isEmpty()) {
+ if (tc.get
ExcludeTopology() != null && tc.getExclude
Topology().isEmpty()) {
return true;
}
if (tc.getExcludeLink() != null && tc.getExcludeLink().isEmpty()) {
return true;
}
if (tc.getExcludeLink() != null && tc.getExcludeLink().isEmpty()) {
@@
-99,7
+99,8
@@
public final class TopoConstraintCheck {
if (tc.getIncludeTopology() != null && tc.getIncludeTopology().isEmpty()) {
return true;
}
if (tc.getIncludeTopology() != null && tc.getIncludeTopology().isEmpty()) {
return true;
}
- return tc.getPreferredTransportLayer() != null && tc.getPreferredTransportLayer().isEmpty();
+ //TODO: check this changes : do not understand the rational of this class
+ return tc.getPreferredTransportLayer() != null && tc.getPreferredTransportLayer() == null;
}
}
}
}