diff options
author | halil.cakal <halil.cakal@est.tech> | 2024-01-23 10:05:36 +0000 |
---|---|---|
committer | halil.cakal <halil.cakal@est.tech> | 2024-02-01 16:41:39 +0000 |
commit | 04280e2f93bbf30e8654c411bb1e107d275c22bb (patch) | |
tree | faf4ac9ae4d80617f6b11cb0d78174e0c12452db /cps-ncmp-service/src/main/java/org/onap/cps/ncmp/api/impl/inventory/InventoryPersistence.java | |
parent | 0f6a966b363e5347de2d44b1527d19b4cf2825a6 (diff) |
Extend API: Get Module Definitions
- add query parameters: module-name and revision to OpenAPI
- extend the controller method to hande the new parameters
- add the new method stack to the service layer
- extend the SQL query to support the new parameters
- add unit and integration testwares
Issue-ID: CPS-1135
Change-Id: I089ad2ad71effb58ac0ba809e9f441d6cdb59c4f
Signed-off-by: halil.cakal <halil.cakal@est.tech>
Diffstat (limited to 'cps-ncmp-service/src/main/java/org/onap/cps/ncmp/api/impl/inventory/InventoryPersistence.java')
-rw-r--r-- | cps-ncmp-service/src/main/java/org/onap/cps/ncmp/api/impl/inventory/InventoryPersistence.java | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/cps-ncmp-service/src/main/java/org/onap/cps/ncmp/api/impl/inventory/InventoryPersistence.java b/cps-ncmp-service/src/main/java/org/onap/cps/ncmp/api/impl/inventory/InventoryPersistence.java index 9024eac33..dcd036870 100644 --- a/cps-ncmp-service/src/main/java/org/onap/cps/ncmp/api/impl/inventory/InventoryPersistence.java +++ b/cps-ncmp-service/src/main/java/org/onap/cps/ncmp/api/impl/inventory/InventoryPersistence.java @@ -80,6 +80,18 @@ public interface InventoryPersistence extends NcmpPersistence { Collection<ModuleDefinition> getModuleDefinitionsByCmHandleId(String cmHandleId); /** + * Method to return module definitions for the given parameters. + * + * @param cmHandleId cm-handle identifier + * @param moduleName module name + * @param moduleRevision the revision of the module + * @return list of module definitions (module name, revision, yang resource content) + */ + Collection<ModuleDefinition> getModuleDefinitionsByCmHandleAndModule(String cmHandleId, + String moduleName, + String moduleRevision); + + /** * Method to return module references by cmHandleId. * * @param cmHandleId cm handle ID |