mdsal.git
4 years agoSpecialize JavaFileTemplate.importedName(Type) 10/85310/1
Robert Varga [Mon, 21 Oct 2019 18:46:29 +0000 (20:46 +0200)]
Specialize JavaFileTemplate.importedName(Type)

95% of call sites do not use annotations, hence we specialize
this method and support it through specialized
AbstractJavaGeneratedType.getReferenceString(Type).

This clearly separates the two codepaths and removes superfluous
checks and indirections in both paths.

Change-Id: I17bfef631d446d71147b17146d5b2cf71a8be623
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove an unused import 07/85307/1
Robert Varga [Mon, 21 Oct 2019 18:27:24 +0000 (20:27 +0200)]
Remove an unused import

This import was left unused after the previous patch, remove it.

JIRA: MDSAL-487
Change-Id: Ie3fe896c64a1cae5c86095dd98386111dcf17959
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdd @NonNull annotation to $YangModuleInfoImpl.qnameOf() 93/85293/5
Robert Varga [Mon, 21 Oct 2019 12:44:33 +0000 (14:44 +0200)]
Add @NonNull annotation to $YangModuleInfoImpl.qnameOf()

YangModuleInfoTemplate has a lot of ceremony when we statically
know the types being used by the template. Concentrate imports
into two sets, instantiate them as strings and be done with it.

Since this takes care of most dynamics, making things much easier
and predictable, we can easily add @NonNull annotations as needed.

JIRA: MDSAL-487
Change-Id: Ic9cd4da1002f3edea6f3fb18f9d49e4a377e145b
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFix spotbugs complaints around logging 95/85295/1
Robert Varga [Mon, 21 Oct 2019 16:52:35 +0000 (18:52 +0200)]
Fix spotbugs complaints around logging

Spotbugs is very much correct about warning about non-constant
format strings. This patch fixes that up.

Change-Id: I8df61b64be1478510e60af99dd2cd2365a98f2c1
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoUse ImmutableSet in YangModuleInfo 94/85294/2
Robert Varga [Mon, 21 Oct 2019 15:23:01 +0000 (17:23 +0200)]
Use ImmutableSet in YangModuleInfo

This allows us to bind to a concrete implementation, improving
performance very slightly.

Change-Id: I2ed60f86ae64895685047d772f31b429aac79d22
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoBump to odlparent-6.0.1/yangtools-4.0.2 65/85265/1
Robert Varga [Sun, 20 Oct 2019 08:53:38 +0000 (10:53 +0200)]
Bump to odlparent-6.0.1/yangtools-4.0.2

This picks up latest upgrades and fixes.

Change-Id: Ib6970d280f73b149e993dbefee29386ccca9ad0a
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFix bug5882 test case 34/85234/5
Robert Varga [Sat, 19 Oct 2019 10:18:54 +0000 (12:18 +0200)]
Fix bug5882 test case

This test case uses illegal duplicate leaves, fix that up.

Change-Id: I3330fafb11b798ab74f9a64b04f4bff8d82b2ce6
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFix invalid augmentations 43/85243/1
Robert Varga [Sat, 19 Oct 2019 12:43:00 +0000 (14:43 +0200)]
Fix invalid augmentations

choice/case structures are collapsed to their parent data tree
node, hence it is invalid to define (in same namespace) the equivalent
of:

container {
  leaf foo { type string; }
  choice some {
    case foo {
      leaf foo { type string; }
    }
  }
}

Fix up the testing model.

Change-Id: I1e3ef8f9b38016e0290221f22b8233fba176bc0e
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit 4e4bb47c41728c15220203602068a5754efbd62f)

4 years agoAdd IetfYangUtil.physAddressBytes() 36/85236/4
Robert Varga [Sat, 19 Oct 2019 10:45:29 +0000 (12:45 +0200)]
Add IetfYangUtil.physAddressBytes()

This adds {mac,phys}AddressBytes() to extract these from well-known
objects.

JIRA: MDSAL-486
Change-Id: Id4a9825be476e4a83bf39c4372340b479dd76164
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdd JavaTypeNames for annotation types 07/85207/1
Robert Varga [Fri, 18 Oct 2019 11:37:00 +0000 (13:37 +0200)]
Add JavaTypeNames for annotation types

We tend to use these quite heavily and each access goes through
the type cache to acquire the JavaTypeName. We can speed things up
a bit by having constants for these annotations.

Change-Id: Id78c92e6f7cca6ecfde85cbe9b986a988acfc9e1
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoMore nullable annotations 06/85206/1
Robert Varga [Tue, 15 Oct 2019 15:28:02 +0000 (17:28 +0200)]
More nullable annotations

This adds a few nullable annotations so eclipse is happier.

Change-Id: I7ce1bb366724413243bdeebc915e5f6978989e9f
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoMake Builders sensitive to @Deprecated annotations 82/85082/3
Robert Varga [Sat, 12 Oct 2019 13:54:37 +0000 (15:54 +0200)]
Make Builders sensitive to @Deprecated annotations

When we are generating a builder for a deprecated type, we need to
consider how it deals with deprecated elements.

There are two scenarios here:

1) status=deprecated -> @Deprecated
In this case it is fair game to produce data, hence the builder
is not deprecated and therefore has @SuppressWarnings("deprecation")

2) status=obsolete -> @Deprecated(forRemoval = true)
In this case the data should not be produced at all, hence
the builder needs to be @Deprecated(forRemoval), too.

We recognize both these conditions and act accordingly. We misue
bug-586 test case to hijack compilation testing.

JIRA: MDSAL-485
Change-Id: I9d08116615cf8c5bdb6a8f4977c9810686618cda
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdd @Deprecated(forRemoval = true) to obsolete elements 83/85083/2
Robert Varga [Sat, 12 Oct 2019 14:06:19 +0000 (16:06 +0200)]
Add @Deprecated(forRemoval = true) to obsolete elements

This adds the functionality to add @Deprecated for removal
annotation to obsolete components.

JIRA: MDSAL-481
Change-Id: I2e23e37e65b799b363a518fc5d737b40e5a64a3c
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoCleanup YangModuleInfoTemplate 18/85118/1
Robert Varga [Tue, 15 Oct 2019 10:32:16 +0000 (12:32 +0200)]
Cleanup YangModuleInfoTemplate

generateModelProvider() returns a string, use the appropriate
template syntax. Also use Map.putIfAbsent() instead of
containsKey()/put() checks.

Change-Id: I48faccd7c87f2ffff51b30d9df04c5cb613df184
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFix boxing warnings 05/85105/1
Robert Varga [Mon, 14 Oct 2019 10:52:01 +0000 (12:52 +0200)]
Fix boxing warnings

Use Boolean.TRUE to fix a warning.

Change-Id: Iff20fe6af6d53351a560f54bed7d0fb426a29fd6
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove unused field from BuilderGeneratorTest 04/85104/1
Robert Varga [Mon, 14 Oct 2019 10:50:39 +0000 (12:50 +0200)]
Remove unused field from BuilderGeneratorTest

We're not using properties, remove the string constant.

Change-Id: If77cac4f65d4e1df54dca30f8ce7e26be6108260
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFix nullness warnings in GeneratorJavaFileTest 03/85103/1
Robert Varga [Mon, 14 Oct 2019 10:49:20 +0000 (12:49 +0200)]
Fix nullness warnings in GeneratorJavaFileTest

Add a simple @NonNullByDefault annotation to utility method to
eliminate some nullness noise.

Change-Id: I41d32f5cf2bbae06c6c82127590c08c5536dc86a
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoBump versions to 5.0.4-SNAPSHOT 58/85058/1
Robert Varga [Fri, 11 Oct 2019 12:57:55 +0000 (14:57 +0200)]
Bump versions to 5.0.4-SNAPSHOT

This starts the next development iteration.

Change-Id: I1359a57ac5409b62d3c1b61d2b166b338be01c62
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdd workarounds for ARIES-1923 52/85052/2
Robert Varga [Fri, 11 Oct 2019 11:12:13 +0000 (13:12 +0200)]
Add workarounds for ARIES-1923

mdsal-binding-api needs it, possibly also spi/util, which we have
just brough to JDK9+ land. Better be safe than sorry.

JIRA: MDSAL-484
Change-Id: Ib2c5c0fbd2fbc2ac083f82423a1d4e918c277cf4
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoDisable slf4j SSL link 53/85053/1
Robert Varga [Fri, 11 Oct 2019 12:00:23 +0000 (14:00 +0200)]
Disable slf4j SSL link

slf4j does not provide apidocs over TLS, link HTTP site instead.

Change-Id: I2158c043a2d9e810a329587159fc6af9d57d8e56
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoMake yang-binding an automatic module 28/85028/1
Robert Varga [Thu, 10 Oct 2019 07:37:09 +0000 (09:37 +0200)]
Make yang-binding an automatic module

This is an API component and while it will need to see some
further movement, we should make it an automatic module. As a
side-effect, this fixes javadoc lookup errors we were seeing
in downstream automatic modules.

Change-Id: I3448918da8673f6ee98511265bda7f3b6659c2a1
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoBump versions to 5.0.3-SNAPSHOT 10/85010/1
Robert Varga [Wed, 9 Oct 2019 07:58:29 +0000 (09:58 +0200)]
Bump versions to 5.0.3-SNAPSHOT

This starts the next development iteration.

Change-Id: I8216eb6e8172171ba64f85082c2c1a76ed2dc212
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoSquash Parameterized types in javadoc references 09/85009/1
Robert Varga [Wed, 9 Oct 2019 05:50:42 +0000 (07:50 +0200)]
Squash Parameterized types in javadoc references

When we are making a reference to a method, any arguments that
are parameterized (such as Class<?>) need to be squashed to their
raw type (such as Class).

JIRA: MDSAL-483
Change-Id: I0d8b596e17ec594a67fdde6f5fc17219aac99a3d
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoBump versions to 5.0.2-SNAPSHOT 76/84876/1
Robert Varga [Wed, 2 Oct 2019 13:01:17 +0000 (15:01 +0200)]
Bump versions to 5.0.2-SNAPSHOT

This starts the next development iteration.

Change-Id: Ib38d9891d20f92db893372bd78e8c491123ae98e
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoBump yangtools to 4.0.1 74/84874/3
Robert Varga [Wed, 2 Oct 2019 11:22:45 +0000 (13:22 +0200)]
Bump yangtools to 4.0.1

This bumps yangtools to 4.0.1 to pick up Uint64 fix. Also fixes
AbstractDOMStoreTreeChangePublisherTest to not muck in
AbstractRegistration internals.

Change-Id: I2d59eb48a42f2b9d1818c8403f6f443fc47d6e1a
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoBump versions to 4.0.1-SNAPSHOT 60/84860/1
Robert Varga [Tue, 1 Oct 2019 19:27:08 +0000 (21:27 +0200)]
Bump versions to 4.0.1-SNAPSHOT

This starts the next development iteration.

Change-Id: I1cd1f5d811fd4ceab6b659d5a6aa27f11bd63e40
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoExpose EffectiveModuleContext from ModuleInfoBackedContext 59/84859/1
Robert Varga [Tue, 1 Oct 2019 19:24:59 +0000 (21:24 +0200)]
Expose EffectiveModuleContext from ModuleInfoBackedContext

This exposes a twin method, so that downstreams can start using
EffectiveModelContext.

JIRA: MDSAL-435
Change-Id: Ie60db53eaf3394fc05ff5eb61b19b4f5833f5e4b
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFix yangtools misbump 56/84856/1
Robert Varga [Tue, 1 Oct 2019 16:34:04 +0000 (18:34 +0200)]
Fix yangtools misbump

I accidentally changed also versions of our utilities, fix that
up.

Change-Id: I5f6428ca3acc1f8162a6861a9ec9ea311a507600
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoBump yangtools to 4.0.0 47/84847/2
Robert Varga [Tue, 1 Oct 2019 12:17:43 +0000 (14:17 +0200)]
Bump yangtools to 4.0.0

yangtools-4.0.0 has been released, this patch adopts that version,
ending the period when we were snapshot-integrated.

Change-Id: I724f264c434ef2efd797ae56e61db9f3e374e425
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoTerminally-deprecate with-parent put()/merge() operations 38/84838/7
Robert Varga [Tue, 1 Oct 2019 10:19:56 +0000 (12:19 +0200)]
Terminally-deprecate with-parent put()/merge() operations

These have been deprecated for some time now, schedule them for
removal.

Change-Id: Id3e6f44add83d37f699fb5642161b552ce8a5465
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove unneeded javax.annotation suppressions 43/84843/4
Robert Varga [Tue, 1 Oct 2019 11:06:12 +0000 (13:06 +0200)]
Remove unneeded javax.annotation suppressions

We do not have javax.annotation dependencies in these components,
remove supressions.

Change-Id: Ie08b1fffb923afb2f5579abc01577b9b786204df
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoTerminally deprecate yang.binding.RpcImplementation 41/84841/5
Robert Varga [Tue, 1 Oct 2019 10:30:04 +0000 (12:30 +0200)]
Terminally deprecate yang.binding.RpcImplementation

We do not seem to have any use for this interface, let's just
schedule it for removal.

Change-Id: Iae2b36320411f89486d0f7def0b144b03ed015c1
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoMove FIXMEs out to 6.0.0 42/84842/5
Robert Varga [Tue, 1 Oct 2019 10:33:15 +0000 (12:33 +0200)]
Move FIXMEs out to 6.0.0

This reschedules FIXMEs so they target next API-incompatible release.

Change-Id: Ica9ea81b2e362acf8dc411ae3d820f5b1139c7ee
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove binding.generator.util.CodeGenerationException 40/84840/3
Robert Varga [Tue, 1 Oct 2019 10:27:57 +0000 (12:27 +0200)]
Remove binding.generator.util.CodeGenerationException

This class is not used anywhere, remove it.

Change-Id: I1b512b23a047e619d1830bf166e1cfb2de9f20f7
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove dom.codec.gen.spi remnants 39/84839/3
Robert Varga [Tue, 1 Oct 2019 10:21:41 +0000 (12:21 +0200)]
Remove dom.codec.gen.spi remnants

This removes the last remnants of the binding-dom-codec SPI contract,
keeping all implementation details internal.

Change-Id: I7f5c71b3abb17737ef0fd8c580260c01bc777c9a
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove BaseYangTypes.UnionType 23/84823/6
Robert Varga [Mon, 30 Sep 2019 21:29:25 +0000 (23:29 +0200)]
Remove BaseYangTypes.UnionType

This class seems to be completely unused, let's remove it.

Change-Id: Iebfd0b9396b3189ccafee59cc1b4ea2a3850fb89
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove superfluous @NonNull 30/84830/2
Robert Varga [Tue, 1 Oct 2019 07:08:01 +0000 (09:08 +0200)]
Remove superfluous @NonNull

We are already using @NonNullByDefault, this additional annotation
is unneeded.

Change-Id: Ibad7236d61f798adff97381c50c3563d7dedf942
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdjust to CodeGenerator using EffectiveModelContext 27/84827/1
Robert Varga [Tue, 1 Oct 2019 06:26:48 +0000 (08:26 +0200)]
Adjust to CodeGenerator using EffectiveModelContext

yangtools has changed the SPI interface in that it is giving us
EffectiveModelContext instead of SchemaContext. Adjust to that.

Change-Id: I2653fd3c0d17402841e774710f43f4d464dcdfe0
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoShare TestModel schema context 22/84822/2
Robert Varga [Mon, 30 Sep 2019 21:27:02 +0000 (23:27 +0200)]
Share TestModel schema context

Even if this takes a few milliseconds, it is useful to share the
the context (as is invariable).

Change-Id: I790932ddbd13c5a12cce27f941785a389b8bb7d8
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdd factory method for malformed messages 21/84821/1
Robert Varga [Mon, 30 Sep 2019 21:15:56 +0000 (23:15 +0200)]
Add factory method for malformed messages

This is a utility method to make it easier for users to create nice
messages when they cannot make sense of a message.

JIRA: MDSAL-455
Change-Id: Ic8292b3d766d53b17a5e3e3dd7fd5a625e7618bc
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdjust for NormalizedNodeStreamWriter.startAnyxmlNode() changing 13/84813/1
Robert Varga [Mon, 30 Sep 2019 15:29:13 +0000 (17:29 +0200)]
Adjust for NormalizedNodeStreamWriter.startAnyxmlNode() changing

The baseline interface now propagates the intended object model,
handle it accordingly.

Change-Id: I9b68801a2a1ee20d86599432fe6b593007836807
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoTerminally deprecate YangSchemaUtils 12/84812/1
Robert Varga [Mon, 30 Sep 2019 15:16:34 +0000 (17:16 +0200)]
Terminally deprecate YangSchemaUtils

This class does not seem to be used anywhere, deprecate it for
removal.

Change-Id: I7ff7e4d21647c43fb8daca410541565bc4052323
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdjust for AnydataExtension being integrated 10/84810/1
Robert Varga [Mon, 30 Sep 2019 11:31:50 +0000 (13:31 +0200)]
Adjust for AnydataExtension being integrated

This updates serialization code to match changes made to
NormalizedNodeStreamWriter -- i.e. AnydataExtension being an
integral part of it.

Change-Id: Id09cec7ba7f7d4359379e9bd74baae4d008b1e63
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdjust for DataTreeTip.prepare() throwing a checked exception 03/84803/1
Robert Varga [Mon, 30 Sep 2019 09:20:29 +0000 (11:20 +0200)]
Adjust for DataTreeTip.prepare() throwing a checked exception

Preparation can now cleanly fail, make sure we account for that
possibility.

Change-Id: I35b3e29b3e21d670768df792db0c9972fab6a74f
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdjust for YangTextSchemaContextResolver return type change 00/84800/1
Robert Varga [Mon, 30 Sep 2019 07:58:33 +0000 (09:58 +0200)]
Adjust for YangTextSchemaContextResolver return type change

The return type of getSchemaContext() changed to return
Optional<? extends SchemaContext>, adjust to that.

Change-Id: I776f29d0a5a9986d7ef394cf76403beb7cde375d
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFix references to Any{Data,Xml}SchemaNode 88/84788/1
Robert Varga [Fri, 27 Sep 2019 14:09:20 +0000 (16:09 +0200)]
Fix references to Any{Data,Xml}SchemaNode

This is a follow-up for renames of AnyXmlSchemaNode and
AnyDataSchemaNode.

Change-Id: I63f9ae94b1bc3fc72385b4ad947a16803d959d0c
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdjust for AnyXmlNode changing its name 86/84786/1
Robert Varga [Fri, 27 Sep 2019 14:05:20 +0000 (16:05 +0200)]
Adjust for AnyXmlNode changing its name

This is a follow-up patch to adjust uses of AnyXmlNode to either
AnyxmlNode or DOMSourceAnyxmlNode.

Change-Id: I98be4147b6515ab939dc9113d4b80c0a589786d0
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoBump odlparent to 6.0.0 85/84685/1
Robert Varga [Tue, 24 Sep 2019 07:43:06 +0000 (09:43 +0200)]
Bump odlparent to 6.0.0

This switches to using a released version of odlparent.

Change-Id: Ia28c3bd0f87de01a993e6811e46012e6aa848383
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRevert "Do not emit empty lists to NormalizedNodes" 71/84571/2
Robert Varga [Sun, 22 Sep 2019 02:12:42 +0000 (04:12 +0200)]
Revert "Do not emit empty lists to NormalizedNodes"

This reverts commit cbe6a8cafaec862f2a918ecc9af99720090d3c8a,
as it is breaing DTO behavior applications explicitly depend on.

The issue cannot be fixed without touching templates, i.e. requires
complete implementation of MDSAL-449.

JIRA: MDSAL-456
Change-Id: I07baf3a7be3867c6bee1b66a05b013ee0ba5171f
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFix space stripping 91/83491/9
Robert Varga [Tue, 6 Aug 2019 15:48:56 +0000 (17:48 +0200)]
Fix space stripping

This fixes the coded intended to strip leading/trailing spaces
from the line builder. This was ineffective due to how xtend
compares char-to-String and would not work anyway, as the stripping
was done in wrong order.

Change-Id: I119ed55492da17355e3f3137dcbb8862259dc44f
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoForce ReadOperations (and TypedReadTransaction) to be implemented 79/84479/1
Robert Varga [Sun, 15 Sep 2019 18:47:23 +0000 (20:47 +0200)]
Force ReadOperations (and TypedReadTransaction) to be implemented

This removes the default implementation, forcing all implementations
to consider this method.

Change-Id: I1f7c9f0a66a5b4c9f95d8f1f9f82691df8a70515
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove superfluous @NonNull annotation 73/84473/1
Robert Varga [Sun, 15 Sep 2019 10:11:14 +0000 (12:11 +0200)]
Remove superfluous @NonNull annotation

MoreObjects.toStringHelper() is not tagged properly, hence generated
toString() methods generate a ton of nullness warnings. Fix that up
by removing the annotation (to mirror what we are otherwise doing
in other methods).

Change-Id: Ib4fc3d3fdd3fab1e5fb257f3e85c344999d6eb1a
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoForce BindingNormalizedNodeSerializers to deal with event instant 14/84414/1
Robert Varga [Fri, 13 Sep 2019 15:56:18 +0000 (17:56 +0200)]
Force BindingNormalizedNodeSerializers to deal with event instant

This is a bit of public API, which was retrofitted. Now make the
eventInstant-aware method mandatory-to-implement.

Change-Id: I9b9287bd62dc2c1ca789e0bc112a92e499ffd246
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoMake BindingCodecTree.getIdentityCodec() non-default 13/84413/1
Robert Varga [Fri, 13 Sep 2019 15:52:22 +0000 (17:52 +0200)]
Make BindingCodecTree.getIdentityCodec() non-default

We want this method implemented, hence make it non-default.

Change-Id: I5fbd6a0685eb508c42d63dce69d716e5efaa4912
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove yang.binding.annotations.(Module)QName 08/84208/6
Robert Varga [Wed, 4 Sep 2019 20:03:17 +0000 (22:03 +0200)]
Remove yang.binding.annotations.(Module)QName

These annotations are scope=runtime and are not used anywhere.
Furthermore they require refection access to classses, so just don't
bother.

Change-Id: Icb23fd1ffbd6ebc18e722ba6f0bff9109db5f356
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoUse String.repeat() instead of Strings.repeat() 88/84288/1
Robert Varga [Tue, 10 Sep 2019 12:29:20 +0000 (14:29 +0200)]
Use String.repeat() instead of Strings.repeat()

Java 11 gives us this neat utility, use it instead of Guava, as it
is coder-aware and does not need to go through 'char'.

Change-Id: I669ddd5e2376d28297695a5f751ec83ff50f7d96
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoGenerate legacy value contructors for all classes 19/84219/4
Robert Varga [Thu, 5 Sep 2019 13:11:38 +0000 (15:11 +0200)]
Generate legacy value contructors for all classes

This expands legacy constructor compatibility to also include
Key classes, not only value wrappers. The codegen parts is relatively
straightforward.

IdentitiableItemCodec is coded on the assumption there are only
two constructors -- one copy and one all-value, which is now violated.

Hence we update IdentifiableItemCodec to also ignore any constructors
which are marked as deprecated.

JIRA: MDSAL-330
Change-Id: Ie23ba8b3788b320b2d11e263c9af228b4c2e41a9
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoMake BaseTemplate.asArguments() take a Collection 18/84218/1
Robert Varga [Thu, 5 Sep 2019 12:25:28 +0000 (14:25 +0200)]
Make BaseTemplate.asArguments() take a Collection

This side-steps the need for IterableExtensions, make the code
a tad faster.

Change-Id: I210d4da343bdae82b81dbb0fd30c6d8ed7d6c13e
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove use of new Integer(String) 17/84217/1
Robert Varga [Thu, 5 Sep 2019 10:05:57 +0000 (12:05 +0200)]
Remove use of new Integer(String)

This constructor has been deprecated in Java 9, migrate to
Integer.valueOf(String) instead.

Change-Id: I5b6dfe27502408bab9ae2f2453dd1a713c00b6bd
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoMake BaseTemplate.fieldName() return String 16/84216/1
Robert Varga [Thu, 5 Sep 2019 10:00:15 +0000 (12:00 +0200)]
Make BaseTemplate.fieldName() return String

Java 9+ has very efficient string concatenations, hence we can
use them. This allows us to better bind to to StringConcatenation,
as we'll end up wired to .append(String) rather than .append(Object),
as would be the case with CharSequences.

Change-Id: I2a93139c1b1af8b4c335aa4a4cb8a68bd76acb95
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdd migration setter @return javadoc 15/84215/1
Robert Varga [Thu, 5 Sep 2019 09:38:22 +0000 (11:38 +0200)]
Add migration setter @return javadoc

This mitigates a warning emitted by javadoc.

JIRA: MDSAL-330
Change-Id: Ic3aa1cc517d7a5d0f3e460d9c1ca353450ae4c66
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoGenerate compatibility constructors for Uint wrapped types 01/84201/2
Robert Varga [Wed, 4 Sep 2019 14:57:10 +0000 (16:57 +0200)]
Generate compatibility constructors for Uint wrapped types

We already are generating compatibility setters, this extends this
capability to wrapper classes (i.e. their constructors). As usual
the compatibility code is marked as deprecated for removal.

Also fixes some code formatting issues introduces in previous
patches.

JIRA: MDSAL-330
Change-Id: I0b2db136c27c26de33f8a756292dde4cdf53bebb
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoSeparate all-values constructor from typedef constructor 98/84198/3
Robert Varga [Wed, 4 Sep 2019 14:03:48 +0000 (16:03 +0200)]
Separate all-values constructor from typedef constructor

ClassTemplate.allValuesContructor() is actually two separate
templates, which is obfuscated by a number of checks. This patch
splits them out, eliminating the need for multiple checks for
the same thing.

JIRA: MDSAL-330
Change-Id: I298299ffe126fe5f51dc9c2776f46245eb0ce563
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoOptimize array checks 00/84200/1
Robert Varga [Wed, 4 Sep 2019 14:24:01 +0000 (16:24 +0200)]
Optimize array checks

Rather than bouncing through .importedName().contains("[]"), we
can make this check through .name().endsWith("[]"), which prevents
a round-trip to import mechanics and is potentially faster.

Change-Id: I4a939333c294ffa94ac1c013a8e3cee466e32cb9
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoCache computed fieldName in templates 99/84199/1
Robert Varga [Wed, 4 Sep 2019 14:17:32 +0000 (16:17 +0200)]
Cache computed fieldName in templates

We end up using the same name multiple times, which really is an
invariant. Cache and reuse the constant, so that we end up with
more efficient code.

Change-Id: I6ee5cc162c43c542a08ba84250f42d9a30ba3f0d
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFix ClassTemplate.genConstructor() declaration 96/84196/2
Robert Varga [Wed, 4 Sep 2019 12:44:47 +0000 (14:44 +0200)]
Fix ClassTemplate.genConstructor() declaration

Using an array here is forcing us to needlessly unwrap the arraylist
(a perfectly iterable thing) to an array, which is only iterater over.

Fix this by passing down an iterable, which means the list can be
passed down as is.

Change-Id: I1572729d554c3ce8ae6ab94c1ba3d5547399e7ab
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAcquire first value manually in ClassTemplate 95/84195/2
Robert Varga [Wed, 4 Sep 2019 12:40:35 +0000 (14:40 +0200)]
Acquire first value manually in ClassTemplate

xtend's get(0) extension ends up creating a temporary list
holding a copy of the (single) value. This is not entirely
efficient, as we can get the same result from plain iterator.

Change-Id: I0f4398a47cb771e8ab7a212a67c5e402d49ffbf2
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAcquire first entry of type constants in BuilderTemplate 94/84194/2
Robert Varga [Wed, 4 Sep 2019 12:30:47 +0000 (14:30 +0200)]
Acquire first entry of type constants in BuilderTemplate

Current code is relying on xtend Conversions to get first entry
from keySet/values separately. That code ends up copying the entire
collection into an array before picking the first element, which
is ... far from optimal.

Peel the first entrySet item using iterator().next() and then
reference key/value from there, which removes a dependency on
Conversions and is way more efficient.

Change-Id: I9cf16c416e65e538697aab26ebb5b9a81965e871
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoOptimize allProperties sorting 92/84192/1
Robert Varga [Wed, 4 Sep 2019 11:55:25 +0000 (13:55 +0200)]
Optimize allProperties sorting

Java 8 has list.sort(), which we can easily short-circuit to
ArrayList's implementation by using 'val' declaration. We can
also make the comparator a constant, so that it is widely reused.

Change-Id: Ib8ce132a806d4e1ab58746ce85e732d451d82845
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoOptimize ClassTemplate.allProperties 91/84191/1
Robert Varga [Wed, 4 Sep 2019 11:46:14 +0000 (13:46 +0200)]
Optimize ClassTemplate.allProperties

This variable is guaranteed to be a List, declare it as such,
adding following benefits:
- eliminates ClassTemplate's reliance on IterableExtensions
- a few isEmpty() checks get be eliminated, as size() is now
  handled through List.size()

Change-Id: I14354dfef3a6b663c9a027353704127437d4344d
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoOptimize BuilderTemplate string references 90/84190/1
Robert Varga [Wed, 4 Sep 2019 11:34:38 +0000 (13:34 +0200)]
Optimize BuilderTemplate string references

AUGMENTATION_FIELD.toFirstUpper is a true constant, make sure we
compute it only once.

Also, in case of augmentable, the augmentable imported name is an
invariant, hence precompute the string and use it multiple times
in the template.

Change-Id: I9607ac2e18e587118659545205323037db176fda
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoBackport code generation test 89/84189/1
Robert Varga [Wed, 4 Sep 2019 11:15:12 +0000 (13:15 +0200)]
Backport code generation test

This backports the model used in binding2 testing.

JIRA: MDSAL-330
Change-Id: I8d2e3998523b78ceccf627134ed92496169a0ca8
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoImprove generated builder documentation 82/84182/3
Robert Varga [Tue, 3 Sep 2019 20:01:24 +0000 (22:01 +0200)]
Improve generated builder documentation

This adds some sorely-needed guidelines as to how to use generated
builders.

Change-Id: I786a7e2f249f336363d4ddc107919edb861e0422
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove BigIntegerRangeGenerator 26/84126/14
Robert Varga [Mon, 2 Sep 2019 14:28:48 +0000 (16:28 +0200)]
Remove BigIntegerRangeGenerator

We do not generate BigIntegers anymore, this removes related
generator.

JIRA: MDSAL-330
Change-Id: I29be15b970e8392f474136c8dd6a948fcbd4054c
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFix Builder javadoc mis-reference 81/84181/2
Robert Varga [Tue, 3 Sep 2019 19:24:17 +0000 (21:24 +0200)]
Fix Builder javadoc mis-reference

Builders should reference target type in their documentation.

Change-Id: I3ba9c31c77be9d86bc4e2d854360b6f8cf0fb86b
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoChange mapping of uint{8,16,32,64} 55/83955/25
Robert Varga [Mon, 2 Sep 2019 08:34:32 +0000 (10:34 +0200)]
Change mapping of uint{8,16,32,64}

This changes the mapping of uint types to non-widening yang.common
classes and deals with them being used by yang.{data,model}.api:

YANG type  Old Java type         New Java Type
uint8      java.lang.Short       org.opendaylight.yangtools.yang.common.Uint8
uint16     java.lang.Integer     org.opendaylight.yangtools.yang.common.Uint16
uint32     java.lang.Long        org.opendaylight.yangtools.yang.common.Uint32
uint64     java.math.BigInteger  org.opendaylight.yangtools.yang.common.Uint64

This affects all getters, setters and value wrapper classes. For
setters, code generator emits a deprecated setter, which performs
the conversion internally.

JIRA: MDSAL-330
JIRA: YANGTOOLS-1018
Change-Id: Ic3913adc4a5d707b01671a982c58221cb028f6d9
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdd a workaround for ARIES-1923 48/84148/1
Robert Varga [Mon, 2 Sep 2019 20:58:28 +0000 (22:58 +0200)]
Add a workaround for ARIES-1923

proxy-impl does not have an Opcodes.ASM7-compatible release, hence
it fails when it encounters JEP-181 nestmates.

As an interim solution, force mdsal-binding-api to target Java 10,
which does not have JEP-181.

Change-Id: I727082c7bc32e905ca4c23f8a35963bc69986f58
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoImprove BindingMapping lookup 34/84134/1
Robert Varga [Mon, 2 Sep 2019 15:57:36 +0000 (17:57 +0200)]
Improve BindingMapping lookup

Expose the fact that JAVA_RESERVED_WORDS is an ImmutableSet,
allowing callers to better bind to it.

Change-Id: I8131aa8d2be9a2b8b1e13f7c5d6231b9ccb5fd2d
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoImprove BaseYangTypes lookups 32/84132/2
Robert Varga [Mon, 2 Sep 2019 15:42:40 +0000 (17:42 +0200)]
Improve BaseYangTypes lookups

Update constant definition to be bound to ImmutableSet, so that
JIT has an easier time optimizing these lookups.

Change-Id: I7becd988d46f84972ef0c573ff5efeadcba2cc62
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoImprove TimerValue builder lookups 29/84129/1
Robert Varga [Mon, 2 Sep 2019 15:13:02 +0000 (17:13 +0200)]
Improve TimerValue builder lookups

The constant is an ImmutableMap, make that explicit, so lookups
can binding directly to it.

Change-Id: Ia4026c5dc10c6e7dcb2e8c2f99709d97e3876e84
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdd a dependency on blueprint annotations 23/84123/2
Robert Varga [Mon, 2 Sep 2019 12:55:20 +0000 (14:55 +0200)]
Add a dependency on blueprint annotations

We are using these and docs is complaining about not being able
to find the classes. Fix that up.

Change-Id: Ibbab75fb1226ff50dbca43e74711dafeb0c40789
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove sun.reflect meddling 97/84097/1
Robert Varga [Fri, 30 Aug 2019 15:11:48 +0000 (17:11 +0200)]
Remove sun.reflect meddling

It seems the issue has been somehow resolved, let's remove the
configuration.

Change-Id: Iee9baeb947c142c5749d5a8ab794fc3871990c56
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove ietf-restconf 88/84088/3
Robert Varga [Fri, 30 Aug 2019 08:24:40 +0000 (10:24 +0200)]
Remove ietf-restconf

This model has been superseded by RFC8040 and there the only
downstream user (netconf.git) is hosting the new version. This
model will live in the restconf projeect until it is needed.

Change-Id: I521d5f720a19c4885df5e8ba3483e6c1af7dbc0b
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFixup leaf caching test in face of lazy leaf nodes 94/84094/2
Robert Varga [Fri, 30 Aug 2019 11:18:02 +0000 (13:18 +0200)]
Fixup leaf caching test in face of lazy leaf nodes

In case we are doing lazy leaves, we end up not retaining them
and hence the test needs to do something different.

Change-Id: I68fded3a799d3c6c023eaa63336b7002ea4594c7
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove use of YangInstanceIdentifier.EMPTY 47/84047/3
Robert Varga [Wed, 28 Aug 2019 19:22:36 +0000 (21:22 +0200)]
Remove use of YangInstanceIdentifier.EMPTY

This constant is deprecated, migrate users to empty().

Change-Id: I8e71f90fb458f1155a0f4fb52ba40595b8e9e6bf
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdd @ConstructorParameters to generated classes 40/84040/3
Robert Varga [Wed, 28 Aug 2019 15:09:12 +0000 (17:09 +0200)]
Add @ConstructorParameters to generated classes

This allows generated classes to be used with both java.beans
and javax.management even either of java.desktop or java.management
module is missing.

JIRA: MDSAL-468
Change-Id: I9903558102d094efeb60201673980685e2b5a253
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoExpose service group name from ServiceGroupIdentifier 41/84041/2
Robert Varga [Wed, 28 Aug 2019 15:34:08 +0000 (17:34 +0200)]
Expose service group name from ServiceGroupIdentifier

AbstractIdentifier has removed public view of getValue(), hence
we need to expose a domain-specific accessor. This patch does that
and fixes up users.

Change-Id: I1645e86e5417e0a8c13660f8820a9df8b4c7cad7
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoSwitch to using VarHandles 48/81848/26
Robert Varga [Wed, 1 May 2019 12:23:15 +0000 (14:23 +0200)]
Switch to using VarHandles

VarHandles allow us to relax the memory ordering when accessing
cached CodecDataObject fields. Use them instead of
AtomicReferenceFieldUpdaters.

Change-Id: If95e4e058491cee4babfcbb49bb7cf47e62f9444
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoOptimize BindingSchemaContextUtils.findDataNodeContainer() 90/83690/5
Robert Varga [Fri, 16 Aug 2019 11:27:00 +0000 (13:27 +0200)]
Optimize BindingSchemaContextUtils.findDataNodeContainer()

The method is performing duplicate instanceof check, refactor it
to to performing only one such check.

Change-Id: I64ba25f4c35dcc5aeaf81e1200ce50a971566973
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoOptimize BindingNormalizedNodeCodecRegistry representation checks 06/83706/4
Robert Varga [Fri, 16 Aug 2019 13:40:24 +0000 (15:40 +0200)]
Optimize BindingNormalizedNodeCodecRegistry representation checks

isBindingRepresentable() is a hot method, which performs a few
type checks. This patch folds those checks into a single return,
inverting the logic (which is negated anyway at the sole caller).
This cuts the amount of byte code to half, thus aiding inlining.

Futhermore we take advantage of ValueNode covering two cases we
explicitly test for, reducing the number of checks performed.

Finally we reorder the checks to improve their efficiency by
tackling most-common constructs first.

Change-Id: I556d1098a9d7dd043b2f8d756c2388f339f6b8ec
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoOptimize IdentifiableItemCodec a bit 64/83964/7
Robert Varga [Mon, 26 Aug 2019 08:47:59 +0000 (10:47 +0200)]
Optimize IdentifiableItemCodec a bit

Do not force instantiation of the backing map, as for single-item
NodeIdentifierWithPredicates it is just wasteful.

Change-Id: I0cc13d0afe2f3329f4757e9da414500de132acf6
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoTake advantage of singleton NodeIdentifierWithPredicates 11/84011/1
Robert Varga [Tue, 27 Aug 2019 11:09:43 +0000 (13:09 +0200)]
Take advantage of singleton NodeIdentifierWithPredicates

NodeIdentifierWithPredicates now includes an efficient single-entry
implementation, which is rendering instantiation through
SharedSingletonMap superfluous. Take advantage of this new
constructor.

Change-Id: I9c724ceeef829ac5dc0cfded38410ab417ed4d47
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove BindingCodec and BindingSerializer 68/83968/2
Robert Varga [Mon, 26 Aug 2019 09:38:38 +0000 (11:38 +0200)]
Remove BindingCodec and BindingSerializer

These interfaces are not used anywhere, remove them.

Change-Id: I7b302cd4f0e397cbe99f2fc1b3d85103ccd47739
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoMass-migrate binding-dom-codec to IllegalArgumentCodec 65/83965/4
Robert Varga [Mon, 26 Aug 2019 08:51:52 +0000 (10:51 +0200)]
Mass-migrate binding-dom-codec to IllegalArgumentCodec

This new interface most closely resembles the old intent behind
concepts.Codec, except it does not quite match nullness guaratees.

JIRA: YANGTOOLS-1017
Change-Id: I7675743ac29834ffa4b15fa70b62d1a3dad2d18b
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoMake IdentifiableItemCodec an IllegalArgumentCodec 63/83963/3
Robert Varga [Mon, 26 Aug 2019 08:43:25 +0000 (10:43 +0200)]
Make IdentifiableItemCodec an IllegalArgumentCodec

The interface contract matches the expectations, hence we can
cleanly apply the pattern.

JIRA: YANGTOOLS-1017
Change-Id: I7b0efcfa0981646071c3715daa691559f923c285
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoMake IdentityCodec an AbstractIllegalArgumentCodec 62/83962/3
Robert Varga [Mon, 26 Aug 2019 08:30:35 +0000 (10:30 +0200)]
Make IdentityCodec an AbstractIllegalArgumentCodec

The behaviour is pretty much the same, except for throwing IAE
on nulls -- this is made consistent to throw a NPE.

JIRA: YANGTOOLS-1017
Change-Id: I23fea88b2c32336400ab1120949507c7442d8076
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoMove Binding codec interfaces 60/83960/3
Robert Varga [Mon, 26 Aug 2019 07:14:49 +0000 (09:14 +0200)]
Move Binding codec interfaces

This moves codec interfaces from yang-binding to binding-dom-codec,
as they are an implementation detail and should never have been
exposed here.

Change-Id: I90a24527d60398ea428eff12f4359501865d3b36
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoGuard generator lookup against nulls 54/83954/1
Robert Varga [Sat, 24 Aug 2019 08:46:16 +0000 (10:46 +0200)]
Guard generator lookup against nulls

If we encounter an unsupported type we can end up throwing a NPE
without any details. This hardens the lookup to verify we have
a hit, and report the type if we have a miss.

Change-Id: I89cb988d8705772065d12b4074775ad9bc538499
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdd missing yanglib docs references 94/83894/1
Robert Varga [Thu, 22 Aug 2019 11:48:08 +0000 (13:48 +0200)]
Add missing yanglib docs references

Reactor build order is showing that we are not documenting
these in mdsal-docs. Fix that.

Change-Id: I649f35d75249f61fb5dd92cd0d2fe56761da336d
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdd missing RFC8542 docs dependency 92/83892/1
Robert Varga [Thu, 22 Aug 2019 11:42:54 +0000 (13:42 +0200)]
Add missing RFC8542 docs dependency

Reactor build order is showing that we have forgotten this
little dependency.

JIRA: MDSAL-431
Change-Id: I2ceb49ba08521c6a2162aacb7e7ecac78f005432
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>