X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=binding%2Fmdsal-binding-spec-util%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Fmdsal%2Fbinding%2Fspec%2Freflect%2FBindingReflections.java;h=0f1dc3e9b90fc2b18ee2ec508e928fc9d4a6c2bc;hb=0ee55d1f9da11dd03ff05fc67d10cbcbfe63fd2c;hp=ef55504e52957f0e39a3dcbe4d70b6e4ecd67dbe;hpb=2037a8c6e17b521c9ccf1ee3a1a965fa96cade3d;p=mdsal.git diff --git a/binding/mdsal-binding-spec-util/src/main/java/org/opendaylight/mdsal/binding/spec/reflect/BindingReflections.java b/binding/mdsal-binding-spec-util/src/main/java/org/opendaylight/mdsal/binding/spec/reflect/BindingReflections.java index ef55504e52..0f1dc3e9b9 100644 --- a/binding/mdsal-binding-spec-util/src/main/java/org/opendaylight/mdsal/binding/spec/reflect/BindingReflections.java +++ b/binding/mdsal-binding-spec-util/src/main/java/org/opendaylight/mdsal/binding/spec/reflect/BindingReflections.java @@ -627,6 +627,11 @@ public final class BindingReflections { * Class which should be used at particular subtree * @return true if and only if classes represents same data. */ + // FIXME: this really should live in BindingRuntimeTypes and should not be based on reflection. The only user is + // binding-dom-codec and the logic could easily be performed on GeneratedType instead. For a particular + // world this boils down to a matrix, which can be calculated either on-demand or when we create + // BindingRuntimeTypes. Achieving that will bring us one step closer to being able to have a pre-compiled + // Binding Runtime. @SuppressWarnings({ "rawtypes", "unchecked" }) public static boolean isSubstitutionFor(final Class potential, final Class target) { Set subImplemented = new HashSet<>(Arrays.asList(potential.getInterfaces()));