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 / PackageInfo.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 com.datastax.driver.mapping.annotations.Column;
24 import com.datastax.driver.mapping.annotations.PartitionKey;
25 import com.datastax.driver.mapping.annotations.Table;
26 import org.openecomp.sdc.versioning.dao.types.Version;
27
28 import java.nio.ByteBuffer;
29
30
31 @Table(keyspace = "dox", name = "package_details")
32 public class PackageInfo {
33
34
35   @PartitionKey
36   @Column(name = "vsp_id")
37   private String vspId;
38
39   @PartitionKey(value = 1)
40   private String version;
41
42   @Column(name = "display_name")
43   private String displayName;
44
45   @Column(name = "vsp_name")
46   private String vspName;
47
48   @Column(name = "vsp_description")
49   private String vspDescription;
50
51   @Column(name = "vendor_name")
52   private String vendorName;
53
54   private String category;
55
56   @Column(name = "sub_category")
57   private String subCategory;
58
59   @Column(name = "vendor_release")
60   private String vendorRelease;
61
62   @Column(name = "package_checksum")
63   private String packageChecksum;
64
65   @Column(name = "package_type")
66   private String packageType;
67
68   @Column(name = "translate_content")
69   private ByteBuffer translatedFile;
70
71   public PackageInfo() {
72   }
73
74   public PackageInfo(String packageId, Version version) {
75     this.vspId = packageId;
76     this.version = version.getName();
77   }
78
79   public String getDisplayName() {
80     return displayName;
81   }
82
83   public void setDisplayName(String displayName) {
84     this.displayName = displayName;
85   }
86
87   public String getVspDescription() {
88     return vspDescription;
89   }
90
91   public void setVspDescription(String vspDescription) {
92     this.vspDescription = vspDescription;
93   }
94
95   public String getVersion() {
96     return version;
97   }
98
99   public void setVersion(String version) {
100     this.version = version;
101   }
102
103   public String getVspId() {
104     return vspId;
105   }
106
107   public void setVspId(String vspId) {
108     this.vspId = vspId;
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 getVendorName() {
128     return vendorName;
129   }
130
131   public void setVendorName(String vendorName) {
132     this.vendorName = vendorName;
133   }
134
135   public String getVendorRelease() {
136     return vendorRelease;
137   }
138
139   public void setVendorRelease(String vendorRelease) {
140     this.vendorRelease = vendorRelease;
141   }
142
143   public String getPackageChecksum() {
144     return packageChecksum;
145   }
146
147   public void setPackageChecksum(String packageChecksum) {
148     this.packageChecksum = packageChecksum;
149   }
150
151   public String getPackageType() {
152     return packageType;
153   }
154
155   public void setPackageType(String packageType) {
156     this.packageType = packageType;
157   }
158
159   public ByteBuffer getTranslatedFile() {
160     return translatedFile;
161   }
162
163   public void setTranslatedFile(ByteBuffer translatedFile) {
164     this.translatedFile = translatedFile;
165   }
166
167   public String getVspName() {
168     return vspName;
169   }
170
171   public void setVspName(String vendorName) {
172     this.vspName = vendorName;
173   }
174 }