2 * ============LICENSE_START=======================================================
\r
4 * ================================================================================
\r
5 * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
\r
6 * ================================================================================
\r
7 * Licensed under the Apache License, Version 2.0 (the "License");
\r
8 * you may not use this file except in compliance with the License.
\r
9 * You may obtain a copy of the License at
\r
11 * http://www.apache.org/licenses/LICENSE-2.0
\r
13 * Unless required by applicable law or agreed to in writing, software
\r
14 * distributed under the License is distributed on an "AS IS" BASIS,
\r
15 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
\r
16 * See the License for the specific language governing permissions and
\r
17 * limitations under the License.
\r
18 * ============LICENSE_END=========================================================
\r
21 package org.openecomp.vid.asdc.beans;
\r
23 import java.util.UUID;
\r
26 * The Class Artifact.
\r
28 public class Artifact {
\r
31 * SDC has widened this to a String type for 1610.
\r
43 ASSET_INVENTORY_PROFILE,
\r
46 VF_MODULES_METADATA,
\r
53 DCAE_INVENTORY_TOSCA,
\r
54 DCAE_INVENTORY_JSON,
\r
57 DCAE_INVENTORY_BLUEPRINT,
\r
58 DCAE_INVENTORY_EVENT,
\r
60 AAI_SERVICE_MODEL //HEY! READ ME! YES, YOU! I AM A TEMPORARY FIX, PLEASE REMOVE ME BECAUSE I AM A FRAUD. I DON'T BELONG HERE.
\r
62 // *The* Artifact.Type.AAI_SERVICE_MODEL Constant
\r
66 /** The artifact name. */
\r
67 private String artifactName;
\r
69 /** The artifact label. */
\r
70 private String artifactLabel;
\r
72 /** The artifact group type. */
\r
73 private String artifactGroupType;
\r
75 /** The artifact type. */
\r
76 private String artifactType;
\r
78 /** The artifact URL. */
\r
79 private String artifactURL;
\r
81 /** The artifact description. */
\r
82 private String artifactDescription;
\r
84 /** The artifact timeout. */
\r
85 private int artifactTimeout;
\r
87 /** The artifact checksum. */
\r
88 private String artifactChecksum;
\r
90 /** The artifact UUID. */
\r
91 private String artifactUUID;
\r
93 /** The artifact version. */
\r
94 private String artifactVersion;
\r
96 /** The generated from UUID. */
\r
97 private String generatedFromUUID;
\r
100 * Gets the artifact name.
\r
102 * @return the artifact name
\r
104 public String getArtifactName() {
\r
105 return artifactName;
\r
109 * Gets the artifact type.
\r
111 * @return the artifact type
\r
113 public String getArtifactType() {
\r
114 return artifactType;
\r
117 * Gets the artifact group type.
\r
119 * @return the artifact group type
\r
121 public String getArtifactGroupType() {
\r
122 return artifactGroupType;
\r
126 * Gets the artifact label.
\r
128 * @return the artifact label
\r
130 public String getArtifactLabel() {
\r
131 return artifactLabel;
\r
134 * Gets the artifact URL.
\r
136 * @return the artifact URL
\r
138 public String getArtifactURL() {
\r
139 return artifactURL;
\r
143 * Gets the artifact description.
\r
145 * @return the artifact description
\r
147 public String getArtifactDescription() {
\r
148 return artifactDescription;
\r
152 * Gets the artifact timeout.
\r
154 * @return the artifact timeout
\r
156 public int getArtifactTimeout() {
\r
157 return artifactTimeout;
\r
161 * Gets the artifact checksum.
\r
163 * @return the artifact checksum
\r
165 public String getArtifactChecksum() {
\r
166 return artifactChecksum;
\r
170 * Gets the artifact UUID.
\r
172 * @return the artifact UUID
\r
174 public String getArtifactUUID() {
\r
175 return artifactUUID;
\r
179 * Gets the artifact version.
\r
181 * @return the artifact version
\r
183 public String getArtifactVersion() {
\r
184 return artifactVersion;
\r
188 * Gets the generated from UUID.
\r
190 * @return the generated from UUID
\r
192 public String getGeneratedFromUUID() {
\r
193 return generatedFromUUID;
\r
197 * Sets the artifact name.
\r
199 * @param artifactName the new artifact name
\r
201 public void setArtifactName(String artifactName) {
\r
202 this.artifactName = artifactName;
\r
206 * Sets the artifact type.
\r
208 * @param artifactType the new artifact type
\r
210 public void setArtifactType(String artifactType) {
\r
211 this.artifactType = artifactType;
\r
214 * Sets the artifact group type.
\r
216 * @param artifactGroupType the new artifact group type
\r
218 public void setArtifactGroupType(String artifactGroupType) {
\r
219 this.artifactGroupType = artifactGroupType;
\r
222 * Sets the artifact label.
\r
224 * @param artifactGroupType the new artifact label
\r
226 public void setArtifactLabel(String artifactLabel) {
\r
227 this.artifactLabel = artifactLabel;
\r
230 * Sets the artifact URL.
\r
232 * @param artifactURL the new artifact URL
\r
234 public void setArtifactURL(String artifactURL) {
\r
235 this.artifactURL = artifactURL;
\r
239 * Sets the artifact description.
\r
241 * @param artifactDescription the new artifact description
\r
243 public void setArtifactDescription(String artifactDescription) {
\r
244 this.artifactDescription = artifactDescription;
\r
248 * Sets the artifact timeout.
\r
250 * @param artifactTimeout the new artifact timeout
\r
252 public void setArtifactTimeout(int artifactTimeout) {
\r
253 this.artifactTimeout = artifactTimeout;
\r
257 * Sets the artifact checksum.
\r
259 * @param artifactChecksum the new artifact checksum
\r
261 public void setArtifactChecksum(String artifactChecksum) {
\r
262 this.artifactChecksum = artifactChecksum;
\r
266 * Sets the artifact UUID.
\r
268 * @param artifactUUID the new artifact UUID
\r
270 public void setArtifactUUID(String artifactUUID) {
\r
271 this.artifactUUID = artifactUUID;
\r
275 * Sets the artifact version.
\r
277 * @param artifactVersion the new artifact version
\r
279 public void setArtifactVersion(String artifactVersion) {
\r
280 this.artifactVersion = artifactVersion;
\r
284 * Sets the generated from UUID.
\r
286 * @param generatedFromUUID the new generated from UUID
\r
288 public void setGeneratedFromUUID(String generatedFromUUID) {
\r
289 this.generatedFromUUID = generatedFromUUID;
\r
293 * @see java.lang.Object#hashCode()
\r
296 public int hashCode() {
\r
297 final UUID uuid = UUID.fromString(getArtifactUUID());
\r
299 return uuid.hashCode();
\r
303 * @see java.lang.Object#equals(java.lang.Object)
\r
306 public boolean equals(Object o) {
\r
307 if (o == this) return true;
\r
308 if (!(o instanceof Artifact)) return false;
\r
310 final Artifact artifact = (Artifact) o;
\r
312 return (artifact.getArtifactUUID().equals(getArtifactUUID()));
\r