7528110d37f8c1e9d1e2bd5772e86739d4cfd37d
[sdc.git] /
1 /*
2  * Copyright © 2016-2018 European Support Limited
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16
17 package org.openecomp.sdc.vendorsoftwareproduct;
18
19 import org.openecomp.sdc.datatypes.error.ErrorMessage;
20 import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComputeEntity;
21 import org.openecomp.sdc.vendorsoftwareproduct.dao.type.OrchestrationTemplateEntity;
22 import org.openecomp.sdc.vendorsoftwareproduct.dao.type.PackageInfo;
23 import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspDetails;
24 import org.openecomp.sdc.vendorsoftwareproduct.types.QuestionnaireResponse;
25 import org.openecomp.sdc.vendorsoftwareproduct.types.ValidationResponse;
26 import org.openecomp.sdc.vendorsoftwareproduct.types.candidateheat.FilesDataStructure;
27 import org.openecomp.sdc.versioning.dao.types.Version;
28
29 import java.io.File;
30 import java.io.IOException;
31 import java.util.Collection;
32 import java.util.List;
33 import java.util.Map;
34 import java.util.Optional;
35
36 public interface VendorSoftwareProductManager {
37
38   VspDetails createVsp(VspDetails vspDetails);
39
40   void updateVsp(VspDetails vspDetails);
41
42   VspDetails getVsp(String vspId, Version version);
43
44   void deleteVsp(String vspIdToDelete);
45
46   ValidationResponse validate(String vspId, Version version) throws IOException;
47
48   Map<String, List<ErrorMessage>> compile(String vspId, Version version);
49
50
51   QuestionnaireResponse getVspQuestionnaire(String vspId, Version version);
52
53   void updateVspQuestionnaire(String vspId, Version version, String questionnaireData);
54
55
56   byte[] getOrchestrationTemplateFile(String vspId, Version version);
57
58   OrchestrationTemplateEntity getOrchestrationTemplateInfo(String vspId, Version version);
59
60   Optional<FilesDataStructure> getOrchestrationTemplateStructure(String vspId, Version version);
61
62   PackageInfo createPackage(String vspId, Version version) throws IOException;
63
64   List<PackageInfo> listPackages(String category, String subCategory);
65
66
67   File getTranslatedFile(String vspId, Version version);
68
69   File getInformationArtifact(String vspId, Version version);
70
71
72   Collection<ComputeEntity> getComputeByVsp(String vspId, Version version);
73 }