Remove unused imports in models
[policy/models.git] / models-provider / src / test / java / org / onap / policy / models / provider / impl / DummyBadProviderImpl.java
index 9320df5..33deed7 100644 (file)
@@ -1,6 +1,8 @@
 /*-
  * ============LICENSE_START=======================================================
- *  Copyright (C) 2019 Nordix Foundation.
+ *  Copyright (C) 2019-2022 Nordix Foundation.
+ *  Modifications Copyright (C) 2019, 2021 AT&T Intellectual Property. All rights reserved.
+ *  Modifications Copyright (C) 2020, 2022 Bell Canada. All rights reserved.
  * ================================================================================
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
 
 package org.onap.policy.models.provider.impl;
 
+import java.util.Collection;
+import java.util.Collections;
 import java.util.List;
 import java.util.Map;
-
 import javax.ws.rs.core.Response;
-
 import lombok.NonNull;
-
-import org.apache.commons.lang3.tuple.Pair;
 import org.onap.policy.models.base.PfModelException;
 import org.onap.policy.models.base.PfModelRuntimeException;
+import org.onap.policy.models.pdp.concepts.Pdp;
 import org.onap.policy.models.pdp.concepts.PdpGroup;
-import org.onap.policy.models.pdp.concepts.PdpGroups;
-import org.onap.policy.models.pdp.concepts.PdpStatistics;
+import org.onap.policy.models.pdp.concepts.PdpGroupFilter;
+import org.onap.policy.models.pdp.concepts.PdpPolicyStatus;
 import org.onap.policy.models.pdp.concepts.PdpSubGroup;
 import org.onap.policy.models.provider.PolicyModelsProvider;
+import org.onap.policy.models.tosca.authorative.concepts.ToscaConceptIdentifierOptVersion;
+import org.onap.policy.models.tosca.authorative.concepts.ToscaEntityFilter;
+import org.onap.policy.models.tosca.authorative.concepts.ToscaEntityKey;
+import org.onap.policy.models.tosca.authorative.concepts.ToscaNodeTemplate;
 import org.onap.policy.models.tosca.authorative.concepts.ToscaPolicy;
 import org.onap.policy.models.tosca.authorative.concepts.ToscaPolicyType;
 import org.onap.policy.models.tosca.authorative.concepts.ToscaServiceTemplate;
-import org.onap.policy.models.tosca.legacy.concepts.LegacyGuardPolicyInput;
-import org.onap.policy.models.tosca.legacy.concepts.LegacyGuardPolicyOutput;
-import org.onap.policy.models.tosca.legacy.concepts.LegacyOperationalPolicy;
+import org.onap.policy.models.tosca.authorative.concepts.ToscaTypedEntityFilter;
 
 /**
  * Dummy implementation of {@link PolicyModelsProvider} with bad constructor.
@@ -53,182 +56,211 @@ public class DummyBadProviderImpl implements PolicyModelsProvider {
     }
 
     @Override
-    public void close() throws Exception {}
+    public void close() throws PfModelException {
+        // do nothing
+    }
 
     @Override
-    public void init() throws PfModelException {}
+    public void init() throws PfModelException {
+        // do nothing
+    }
 
     @Override
-    public ToscaServiceTemplate getPolicyTypes(final String name, final String version) throws PfModelException {
+    public List<ToscaServiceTemplate> getFilteredServiceTemplateList(
+            @NonNull ToscaEntityFilter<ToscaServiceTemplate> filter) throws PfModelException {
         return null;
     }
 
     @Override
-    public ToscaServiceTemplate createPolicyTypes(@NonNull ToscaServiceTemplate serviceTemplate)
+    public ToscaServiceTemplate createServiceTemplate(@NonNull ToscaServiceTemplate serviceTemplate)
             throws PfModelException {
         return null;
     }
 
     @Override
-    public ToscaServiceTemplate updatePolicyTypes(@NonNull ToscaServiceTemplate serviceTemplate)
+    public ToscaServiceTemplate updateServiceTemplate(@NonNull ToscaServiceTemplate serviceTemplate)
             throws PfModelException {
         return null;
     }
 
     @Override
-    public ToscaServiceTemplate deletePolicyType(final String name, final String version) throws PfModelException {
+    public ToscaServiceTemplate deleteServiceTemplate(@NonNull String name, @NonNull String version)
+            throws PfModelException {
         return null;
     }
 
     @Override
-    public ToscaServiceTemplate getPolicies(final String name, final String version) throws PfModelException {
+    public ToscaServiceTemplate getPolicyTypes(final String name, final String version) throws PfModelException {
         return null;
     }
 
     @Override
-    public ToscaServiceTemplate createPolicies(@NonNull ToscaServiceTemplate serviceTemplate)
+    public ToscaServiceTemplate createPolicyTypes(@NonNull ToscaServiceTemplate serviceTemplate)
             throws PfModelException {
         return null;
     }
 
     @Override
-    public ToscaServiceTemplate updatePolicies(@NonNull ToscaServiceTemplate serviceTemplate)
+    public ToscaServiceTemplate updatePolicyTypes(@NonNull ToscaServiceTemplate serviceTemplate)
             throws PfModelException {
         return null;
     }
 
     @Override
-    public ToscaServiceTemplate deletePolicy(final String name, final String version) throws PfModelException {
+    public ToscaServiceTemplate deletePolicyType(final String name, final String version) throws PfModelException {
         return null;
     }
 
     @Override
-    public LegacyOperationalPolicy getOperationalPolicy(@NonNull String policyId) throws PfModelException {
+    public ToscaServiceTemplate getPolicies(final String name, final String version) throws PfModelException {
         return null;
     }
 
     @Override
-    public LegacyOperationalPolicy createOperationalPolicy(@NonNull LegacyOperationalPolicy legacyOperationalPolicy)
-            throws PfModelException {
+    public ToscaServiceTemplate createPolicies(@NonNull ToscaServiceTemplate serviceTemplate) throws PfModelException {
         return null;
     }
 
     @Override
-    public LegacyOperationalPolicy updateOperationalPolicy(@NonNull LegacyOperationalPolicy legacyOperationalPolicy)
-            throws PfModelException {
+    public ToscaServiceTemplate updatePolicies(@NonNull ToscaServiceTemplate serviceTemplate) throws PfModelException {
         return null;
     }
 
     @Override
-    public LegacyOperationalPolicy deleteOperationalPolicy(@NonNull String policyId) throws PfModelException {
+    public ToscaServiceTemplate deletePolicy(final String name, final String version) throws PfModelException {
         return null;
     }
 
     @Override
-    public Map<String, LegacyGuardPolicyOutput> getGuardPolicy(@NonNull String policyId) throws PfModelException {
+    public ToscaServiceTemplate createToscaNodeTemplates(@NonNull ToscaServiceTemplate serviceTemplate)
+        throws PfModelException {
         return null;
     }
 
     @Override
-    public Map<String, LegacyGuardPolicyOutput> createGuardPolicy(@NonNull LegacyGuardPolicyInput legacyGuardPolicy)
-            throws PfModelException {
+    public ToscaServiceTemplate updateToscaNodeTemplates(@NonNull ToscaServiceTemplate serviceTemplate)
+        throws PfModelRuntimeException, PfModelException {
         return null;
     }
 
     @Override
-    public Map<String, LegacyGuardPolicyOutput> updateGuardPolicy(@NonNull LegacyGuardPolicyInput legacyGuardPolicy)
-            throws PfModelException {
+    public ToscaServiceTemplate deleteToscaNodeTemplate(@NonNull String name, @NonNull String version)
+        throws PfModelException {
         return null;
     }
 
     @Override
-    public Map<String, LegacyGuardPolicyOutput> deleteGuardPolicy(@NonNull String policyId) throws PfModelException {
+    public List<Map<ToscaEntityKey, Map<String, Object>>> getNodeTemplateMetadataSets(@NonNull String name,
+                                                                                      @NonNull String version)
+        throws PfModelException {
         return null;
     }
 
     @Override
-    public PdpGroups getPdpGroups(String name, String version) throws PfModelException {
+    public List<ToscaNodeTemplate> getToscaNodeTemplate(final String name, final String version)
+        throws PfModelException {
         return null;
     }
 
     @Override
-    public PdpGroups createPdpGroups(@NonNull PdpGroups pdpGroups) throws PfModelException {
-        return null;
+    public List<PdpGroup> getPdpGroups(String name) throws PfModelException {
+        return Collections.emptyList();
     }
 
     @Override
-    public PdpGroups updatePdpGroups(@NonNull PdpGroups pdpGroups) throws PfModelException {
-        return null;
+    public List<PdpGroup> createPdpGroups(@NonNull List<PdpGroup> pdpGroups) throws PfModelException {
+        return Collections.emptyList();
+    }
+
+    @Override
+    public List<PdpGroup> updatePdpGroups(@NonNull List<PdpGroup> pdpGroups) throws PfModelException {
+        return Collections.emptyList();
     }
 
     @Override
-    public PdpGroup deletePdpGroup(@NonNull String name, @NonNull String verison) throws PfModelException {
+    public void updatePdp(@NonNull String pdpGroupName, @NonNull String pdpSubGroup, @NonNull Pdp pdp)
+            throws PfModelException {
+        // do nothing
+    }
+
+    @Override
+    public PdpGroup deletePdpGroup(@NonNull String name) throws PfModelException {
         return null;
     }
 
     @Override
     public List<ToscaPolicyType> getPolicyTypeList(String name, String version) throws PfModelException {
-        return null;
+        return Collections.emptyList();
     }
 
     @Override
-    public ToscaServiceTemplate getLatestPolicyTypes(String name) throws PfModelException {
+    public ToscaServiceTemplate getFilteredPolicyTypes(@NonNull ToscaEntityFilter<ToscaPolicyType> filter)
+            throws PfModelException {
         return null;
     }
 
     @Override
-    public List<ToscaPolicyType> getLatestPolicyTypeList(String name) throws PfModelException {
-        return null;
+    public List<ToscaPolicyType> getFilteredPolicyTypeList(@NonNull ToscaEntityFilter<ToscaPolicyType> filter)
+            throws PfModelException {
+        return Collections.emptyList();
     }
 
     @Override
     public List<ToscaPolicy> getPolicyList(String name, String version) throws PfModelException {
-        return null;
+        return Collections.emptyList();
     }
 
     @Override
-    public List<ToscaPolicy> getPolicyList4PolicyType(@NonNull String policyTypeName) throws PfModelException {
+    public ToscaServiceTemplate getFilteredPolicies(@NonNull ToscaTypedEntityFilter<ToscaPolicy> filter)
+            throws PfModelException {
         return null;
     }
 
     @Override
-    public ToscaServiceTemplate getLatestPolicies(String name) throws PfModelException {
-        return null;
+    public List<ToscaPolicy> getFilteredPolicyList(@NonNull ToscaTypedEntityFilter<ToscaPolicy> filter)
+            throws PfModelException {
+        return Collections.emptyList();
     }
 
     @Override
-    public List<ToscaPolicy> getLatestPolicyList(String name) throws PfModelException {
-        return null;
+    public List<PdpGroup> getFilteredPdpGroups(@NonNull PdpGroupFilter filter) throws PfModelException {
+        return Collections.emptyList();
     }
 
     @Override
-    public PdpGroups getLatestPdpGroups(String name) throws PfModelException {
-        return null;
+    public void updatePdpSubGroup(@NonNull String pdpGroupName, @NonNull PdpSubGroup pdpSubGroup)
+            throws PfModelException {
+        // do nothing
     }
 
     @Override
-    public PdpGroups getFilteredPdpGroups(@NonNull String pdpType,
-            @NonNull List<Pair<String, String>> supportedPolicyTypes) {
+    public List<PdpPolicyStatus> getAllPolicyStatus() throws PfModelException {
+        // Not implemented
         return null;
     }
 
     @Override
-    public void updatePdpSubGroup(@NonNull String pdpGroupName, @NonNull String pdpGroupVersion,
-            @NonNull PdpSubGroup pdpSubGroup) throws PfModelException {
+    public List<PdpPolicyStatus> getAllPolicyStatus(@NonNull ToscaConceptIdentifierOptVersion policy)
+            throws PfModelException {
+        // Not implemented
+        return null;
     }
 
     @Override
-    public List<PdpStatistics> getPdpStatistics(String name, String version) throws PfModelException {
+    public List<PdpPolicyStatus> getGroupPolicyStatus(@NonNull String groupName) throws PfModelException {
+        // Not implemented
         return null;
     }
 
     @Override
-    public void updatePdpStatistics(@NonNull String pdpGroupName, @NonNull String pdpGroupVersion,
-            @NonNull String pdpType, @NonNull String pdpInstanceId, @NonNull PdpStatistics pdppStatistics) {
+    public void cudPolicyStatus(Collection<PdpPolicyStatus> createObjs, Collection<PdpPolicyStatus> updateObjs,
+            Collection<PdpPolicyStatus> deleteObjs) {
+        // Not implemented
     }
 
     @Override
-    public Map<PdpGroup, List<ToscaPolicy>> getDeployedPolicyList(String name) throws PfModelException {
+    public List<ToscaServiceTemplate> getServiceTemplateList(String name, String version) throws PfModelException {
+        // Not implemented
         return null;
     }
 }