Merge "Descendants description changed in openApi"
[cps.git] / cps-service / src / main / java / org / onap / cps / spi / CpsModulePersistenceService.java
index db2cb60..f5dc8ac 100755 (executable)
@@ -2,6 +2,7 @@
  * ============LICENSE_START=======================================================
  *  Copyright (C) 2020-2022 Nordix Foundation
  *  Modifications Copyright (C) 2020-2022 Bell Canada.
+ *  Modifications Copyright (C) 2022 TechMahindra Ltd.
  *  ================================================================================
  *  Licensed under the Apache License, Version 2.0 (the "License");
  *  you may not use this file except in compliance with the License.
@@ -25,6 +26,7 @@ import java.util.Collection;
 import java.util.Map;
 import org.onap.cps.spi.model.ModuleDefinition;
 import org.onap.cps.spi.model.ModuleReference;
+import org.onap.cps.spi.model.SchemaSet;
 
 /**
  * Service to manage modules.
@@ -43,13 +45,21 @@ public interface CpsModulePersistenceService {
     /**
      * Stores a schema set from new modules and existing modules.
      *
-     * @param dataspaceName                          Dataspace name
-     * @param schemaSetName                          Schema set name
+     * @param dataspaceName             Dataspace name
+     * @param schemaSetName             Schema set name
      * @param newModuleNameToContentMap YANG resources map where key is a module name and value is content
-     * @param moduleReferences                       List of YANG resources module references
+     * @param allModuleReferences       All YANG resources module references
      */
     void storeSchemaSetFromModules(String dataspaceName, String schemaSetName,
-        Map<String, String> newModuleNameToContentMap, Collection<ModuleReference> moduleReferences);
+        Map<String, String> newModuleNameToContentMap, Collection<ModuleReference> allModuleReferences);
+
+    /**
+     * Get all schema sets for a given dataspace.
+     *
+     * @param dataspaceName dataspace name.
+     * @return List of schema sets
+     */
+    Collection<SchemaSet> getSchemaSetsByDataspaceName(String dataspaceName);
 
     /**
      * Deletes Schema Set.