Add collaboration feature
[sdc.git] / openecomp-be / lib / openecomp-sdc-vendor-software-product-lib / openecomp-sdc-vendor-software-product-api / src / main / java / org / openecomp / sdc / vendorsoftwareproduct / dao / type / VspDetails.java
1 /*-
2  * ============LICENSE_START=======================================================
3  * SDC
4  * ================================================================================
5  * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
6  * ================================================================================
7  * Licensed under the Apache License, Version 2.0 (the "License");
8  * you may not use this file except in compliance with the License.
9  * You may obtain a copy of the License at
10  *
11  *      http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing, software
14  * distributed under the License is distributed on an "AS IS" BASIS,
15  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16  * See the License for the specific language governing permissions and
17  * limitations under the License.
18  * ============LICENSE_END=========================================================
19  */
20
21 package org.openecomp.sdc.vendorsoftwareproduct.dao.type;
22
23 import org.openecomp.sdc.versioning.dao.types.Version;
24 import org.openecomp.sdc.versioning.dao.types.VersionableEntity;
25
26 import java.util.List;
27
28
29 public class VspDetails implements VersionableEntity {
30   public static final String ENTITY_TYPE = "Vendor Software Product";
31
32   private String id;
33
34   private Version version;
35
36   private String name;
37   private String description;
38
39   private String category;
40
41   private String subCategory;
42
43   private String icon;
44
45   private String vendorName;
46
47   private String vendorId;
48
49   private Version vlmVersion;
50
51   private String licenseAgreement;
52
53   private List<String> featureGroups;
54
55   private Long writetimeMicroSeconds;
56
57   private String onboardingMethod;
58
59   public VspDetails() {
60   }
61
62   public VspDetails(String id, Version version) {
63     this.id = id;
64     this.version = version;
65   }
66
67   @Override
68   public String getEntityType() {
69     return ENTITY_TYPE;
70   }
71
72   @Override
73   public String getFirstClassCitizenId() {
74     return getId();
75   }
76
77   public String getId() {
78     return id;
79   }
80
81   public void setId(String id) {
82     this.id = id;
83   }
84
85   @Override
86   public Version getVersion() {
87     return version;
88   }
89
90   @Override
91   public void setVersion(Version version) {
92     this.version = version;
93   }
94
95   public String getName() {
96     return name;
97   }
98
99   public void setName(String name) {
100     this.name = name;
101   }
102
103   public String getDescription() {
104     return description;
105   }
106
107   public void setDescription(String description) {
108     this.description = description;
109   }
110
111   public String getCategory() {
112     return category;
113   }
114
115   public void setCategory(String category) {
116     this.category = category;
117   }
118
119   public String getSubCategory() {
120     return subCategory;
121   }
122
123   public void setSubCategory(String subCategory) {
124     this.subCategory = subCategory;
125   }
126
127   public String getIcon() {
128     return icon;
129   }
130
131   public void setIcon(String icon) {
132     this.icon = icon;
133   }
134
135   public String getVendorName() {
136     return vendorName;
137   }
138
139   public void setVendorName(String vendorName) {
140     this.vendorName = vendorName;
141   }
142
143   public String getVendorId() {
144     return vendorId;
145   }
146
147   public void setVendorId(String vendorId) {
148     this.vendorId = vendorId;
149   }
150
151   public Version getVlmVersion() {
152     return vlmVersion;
153   }
154
155   public void setVlmVersion(Version vlmVersion) {
156     this.vlmVersion = vlmVersion;
157   }
158
159   public String getLicenseAgreement() {
160     return licenseAgreement;
161   }
162
163   public void setLicenseAgreement(String licenseAgreement) {
164     this.licenseAgreement = licenseAgreement;
165   }
166
167   public List<String> getFeatureGroups() {
168     return featureGroups;
169   }
170
171   public void setFeatureGroups(List<String> featureGroups) {
172     this.featureGroups = featureGroups;
173   }
174
175   public Long getWritetimeMicroSeconds() {
176     return this.writetimeMicroSeconds;
177   }
178
179   public void setWritetimeMicroSeconds(Long writetimeMicroSeconds) {
180     this.writetimeMicroSeconds = writetimeMicroSeconds;
181   }
182
183   /*public boolean isOldVersion() {
184     return this.oldVersion;
185   }*/
186
187   public String getOnboardingMethod() {
188     return onboardingMethod;
189   }
190
191   public void setOnboardingMethod(String onboardingMethod) {
192     this.onboardingMethod = onboardingMethod;
193   }
194
195
196   @Override
197   public String toString() {
198     return String.format(
199         "Vsp id = '%s', Version = %s', Name = %s', Category = %s', Description = %s', Vendor = %s'",
200         this.id, this.version, this.name, this.category, this.description, this.vendorName);
201   }
202 }