-
Story
-
Resolution: Done
-
Medium
-
None
-
None
This story removes all references to var args AAIUriFactory.createResourceUri() method signatures.
Existing code that looks like:
createResourceUri(AAIObjectType.X, key1, key2, key3) has been replaced with AAIFluentTypeBuilder.root().type(key1).type(key2).type(key3). This provides compile time verification that you have constructed the type with all required keys.
There are two exceptions which will be dealt with more elegantly later - Service Instance and Allotted Resource.
These two have a special property which allows them to be retrieved uniquely with a single key. This has been implemented initially as:
createResourceUri(Type.SERVICE_INSTANCE.getFragment(key1))
"Fragments" allow you to access the partial uri section of a service instance e.g. /service-instances/service-instance/{id} however this special retrieve requires an under the covers call to a separate API and only Service Instance and Allotted resource have this.