re base code
[sdc.git] / catalog-be / src / main / java / org / openecomp / sdc / be / components / merge / capability / CapabilityResolver.java
1 package org.openecomp.sdc.be.components.merge.capability;
2
3 import org.openecomp.sdc.be.model.CapabilityDefinition;
4 import org.openecomp.sdc.be.model.Component;
5 import org.openecomp.sdc.be.model.ComponentInstance;
6
7 import java.util.List;
8 import java.util.Map;
9
10 public interface CapabilityResolver {
11
12     /**
13      *
14      * @param container the instance container
15      * @param prevInstanceOrigNode the prev instance's original node type
16      * @param cmptInstanceId the current instance id
17      * @param prevCapabilities list of previous capabilities for which to find their corresponding new capabilities
18      * @return a mapping between the prev capability to its corresponding new capability (if exists)
19      */
20     Map<CapabilityDefinition, CapabilityDefinition> resolvePrevCapToNewCapability(Component container, Component prevInstanceOrigNode, String cmptInstanceId, List<CapabilityDefinition> prevCapabilities);
21
22     /**
23      *
24      * @param oldInstance the old instance of which its capabilities are to be mapped as the key
25      * @param currInstance the curr instance of which its capabilities are to be mapped as the value
26      * @return a mapping between the prev capability to its corresponding new capability (if exists)
27      */
28     Map<CapabilityDefinition, CapabilityDefinition> resolvePrevCapIdToNewCapability(ComponentInstance oldInstance, ComponentInstance currInstance);
29 }