diff options
author | Maros Marsalek <mmarsale@cisco.com> | 2016-06-08 20:51:32 +0200 |
---|---|---|
committer | Maros Marsalek <mmarsale@cisco.com> | 2016-06-09 18:24:23 +0200 |
commit | 973d8c2ecbb02cf6e4971060b6edec3617bce96f (patch) | |
tree | 84d2907763553be76a1573cbeca58f14713c380d /v3po/translate-impl/src/main | |
parent | e17470c944ae71202cf438bf36f87b4e032618ed (diff) |
HONEYCOMB-62: Add Ip readers
+ Fix 1 interface reads. Interface reader worked only
if GET interfaces-state was executed
+ Fix readSubtree for augmentations. Comoposite readers did
not check child readers for augmentations, only direct children.
Change-Id: I2bc433e3e5785453062ab262b9edabc72c333bf0
Signed-off-by: Maros Marsalek <mmarsale@cisco.com>
Diffstat (limited to 'v3po/translate-impl/src/main')
-rw-r--r-- | v3po/translate-impl/src/main/java/io/fd/honeycomb/v3po/translate/impl/read/AbstractCompositeReader.java | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/v3po/translate-impl/src/main/java/io/fd/honeycomb/v3po/translate/impl/read/AbstractCompositeReader.java b/v3po/translate-impl/src/main/java/io/fd/honeycomb/v3po/translate/impl/read/AbstractCompositeReader.java index f026d4f92..afd979167 100644 --- a/v3po/translate-impl/src/main/java/io/fd/honeycomb/v3po/translate/impl/read/AbstractCompositeReader.java +++ b/v3po/translate-impl/src/main/java/io/fd/honeycomb/v3po/translate/impl/read/AbstractCompositeReader.java @@ -141,10 +141,14 @@ abstract class AbstractCompositeReader<D extends DataObject, B extends Builder<D LOG.debug("{}: Reading subtree: {}", this, id); final Class<? extends DataObject> next = RWUtils.getNextId(id, getManagedDataObjectType()).getType(); final ChildReader<? extends ChildOf<D>> reader = childReaders.get(next); + final ChildReader<? extends Augmentation<D>> augReader = augReaders.get(next); if (reader != null) { LOG.debug("{}: Reading subtree: {} from: {}", this, id, reader); return reader.read(id, ctx); + }if (augReader != null) { + LOG.debug("{}: Reading subtree: {} from: {}", this, id, augReader); + return augReader.read(id, ctx); } else { LOG.debug("{}: Dedicated subtree reader missing for: {}. Reading current and filtering", this, next); // If there's no dedicated reader, use read current |