G
- Grouping typeT
- Augmentable type@Beta public final class AugmentationGroupingResolver<G extends org.opendaylight.yangtools.yang.binding.DataObject,T extends org.opendaylight.yangtools.yang.binding.Augmentable<T>> extends Object implements org.opendaylight.yangtools.concepts.Immutable
Typical use case is, given a base grouping module:
module foo; grouping foo { container augmentable { } }and a module independent of it:
module bar; container bar { uses foo:foo; }and
module baz; container baz { uses foo:foo; }an external module can perform:
module xyzzy; import bar { prefix bar; } import baz { prefix baz; } grouping something { // ... } augment /bar:bar/bar:augmentable { uses something; } augment /baz:baz/baz:augmentable { uses something; }The augmentations of
bar
and baz
instantiations of grouping foo
have an equivalent
augmentation introduced by xyzzy
. This equivalence is not expressed is generated code, in that it is
not apparent given bar
or baz
there is an augmentation which provides something
.
This class provides the static knowledge to ask for the contents of something
given an instance of
augmentable
, without knowing which augmentation introduces it.
Modifier and Type | Class and Description |
---|---|
static class |
AugmentationGroupingResolver.Builder<G extends org.opendaylight.yangtools.yang.binding.DataObject,T extends org.opendaylight.yangtools.yang.binding.Augmentable<T>> |
static class |
AugmentationGroupingResolver.Factory<T extends org.opendaylight.yangtools.yang.binding.Augmentable<T>> |
Modifier and Type | Method and Description |
---|---|
static <G extends org.opendaylight.yangtools.yang.binding.DataObject,T extends org.opendaylight.yangtools.yang.binding.Augmentable<T>> |
builder(Class<G> groupingClass) |
static <T extends org.opendaylight.yangtools.yang.binding.Augmentable<T>> |
factory(Class<T> augmentableClass,
Set<Class<? extends org.opendaylight.yangtools.yang.binding.Augmentation<T>>> augmentationClasses) |
@NonNull Optional<G> |
findExtension(T data) |
public static <G extends org.opendaylight.yangtools.yang.binding.DataObject,T extends org.opendaylight.yangtools.yang.binding.Augmentable<T>> @NonNull AugmentationGroupingResolver.Builder<G,T> builder(Class<G> groupingClass)
public static <T extends org.opendaylight.yangtools.yang.binding.Augmentable<T>> @NonNull AugmentationGroupingResolver.Factory<T> factory(Class<T> augmentableClass, Set<Class<? extends org.opendaylight.yangtools.yang.binding.Augmentation<T>>> augmentationClasses)
Copyright © 2020 OpenDaylight. All rights reserved.