diff options
author | 2022-08-03 11:59:43 -0400 | |
---|---|---|
committer | 2022-08-05 16:10:18 -0400 | |
commit | 219b28ed3c3ee23f10d67c9c50583a8bd5a84f3a (patch) | |
tree | e3d5654f7cb1c16d899d652ab25c97992bf635b6 /generic-resource-api/provider/src/test/java/org/onap/sdnc/northbound/util/MDSALUtil.java | |
parent | 2b1dc5b10650ed62f71d4b84ef662b59ed663fc1 (diff) |
Changes to support ODL Sulfur update
Changes to sdnc/northbound to conform to changes in OpenDaylight Sulfur
release. Many of these changes are due to a change in yangtools, which
no longer implements a common ancestor for its builder classes. This broke
a utility method used in jUnit test cases (build()), which meant all
jUnits using that method had to be updated to call each individual
builder's build() method directly.
Issue-ID: CCSDK-1728
Signed-off-by: Dan Timoney <dtimoney@att.com>
Change-Id: Ia82aa3decd82d873120dd643a6a0427928890f99
Diffstat (limited to 'generic-resource-api/provider/src/test/java/org/onap/sdnc/northbound/util/MDSALUtil.java')
-rw-r--r-- | generic-resource-api/provider/src/test/java/org/onap/sdnc/northbound/util/MDSALUtil.java | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/generic-resource-api/provider/src/test/java/org/onap/sdnc/northbound/util/MDSALUtil.java b/generic-resource-api/provider/src/test/java/org/onap/sdnc/northbound/util/MDSALUtil.java index 840b4228..5db09f92 100644 --- a/generic-resource-api/provider/src/test/java/org/onap/sdnc/northbound/util/MDSALUtil.java +++ b/generic-resource-api/provider/src/test/java/org/onap/sdnc/northbound/util/MDSALUtil.java @@ -92,7 +92,6 @@ import org.opendaylight.yang.gen.v1.org.onap.sdnc.northbound.generic.resource.re import org.opendaylight.yang.gen.v1.org.onap.sdnc.northbound.generic.resource.rev170824.pnf.details.PnfDetailsBuilder; import org.opendaylight.yang.gen.v1.org.onap.sdnc.northbound.generic.resource.rev170824.pnf.response.information.PnfResponseInformationBuilder; import org.opendaylight.yang.gen.v1.org.onap.sdnc.northbound.generic.resource.rev170824.pnf.topology.identifier.structure.PnfTopologyIdentifierStructureBuilder; -import org.opendaylight.yangtools.concepts.Builder; import org.opendaylight.yangtools.yang.common.RpcResult; @@ -353,28 +352,6 @@ public class MDSALUtil { return new ServiceLevelOperStatusBuilder(); } - public static <P> P build(Builder<P> b) { - return b == null ? null : b.build(); - } - - public static <P, B extends Builder<P>> P build(Function<P, B> builderConstructor, P sourceDataObject) { - if (sourceDataObject == null) { - return null; - } - B bp = builderConstructor.apply(sourceDataObject); - return bp.build(); - } - - public static <P, B extends Builder<P>> P build(Function<P, B> builderConstructor, P sourceDataObject, - Consumer<B> builder) { - if (sourceDataObject == null) { - return null; - } - B bp = builderConstructor.apply(sourceDataObject); - builder.accept(bp); - return bp.build(); - } - public static <I, O> O exec(Function<I, Future<RpcResult<O>>> rpc, I rpcParameter, Function<RpcResult<O>, O> rpcResult) throws Exception { Future<RpcResult<O>> future = rpc.apply(rpcParameter); |