2 * ============LICENSE_START=======================================================
4 * ================================================================================
5 * Copyright © 2017-2018 AT&T Intellectual Property. All rights reserved.
6 * Copyright © 2017-2018 European Software Marketing Ltd.
7 * ================================================================================
8 * Licensed under the Apache License, Version 2.0 (the "License");
9 * you may not use this file except in compliance with the License.
10 * You may obtain a copy of the License at
12 * http://www.apache.org/licenses/LICENSE-2.0
14 * Unless required by applicable law or agreed to in writing, software
15 * distributed under the License is distributed on an "AS IS" BASIS,
16 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17 * See the License for the specific language governing permissions and
18 * limitations under the License.
19 * ============LICENSE_END=========================================================
21 package org.onap.aai.babel.csar.fixture;
23 import java.util.Objects;
24 import org.apache.commons.lang3.builder.EqualsBuilder;
25 import org.openecomp.sdc.api.notification.IArtifactInfo;
28 * This class is an implementation of IArtifactInfo for test purposes.
30 public class TestArtifactInfoImpl implements IArtifactInfo {
32 private String artifactName;
33 private String artifactType;
34 private String artifactDescription;
35 private String artifactVersion;
38 public String getArtifactName() {
42 void setArtifactName(String artifactName) {
43 this.artifactName = artifactName;
47 public String getArtifactType() {
51 void setArtifactType(String artifactType) {
52 this.artifactType = artifactType;
56 public String getArtifactURL() {
61 public String getArtifactChecksum() {
66 public String getArtifactDescription() {
67 return artifactDescription;
70 void setArtifactDescription(String artifactDescription) {
71 this.artifactDescription = artifactDescription;
75 public Integer getArtifactTimeout() {
80 public String getArtifactVersion() {
81 return artifactVersion;
84 void setArtifactVersion(String artifactVersion) {
85 this.artifactVersion = artifactVersion;
89 public String getArtifactUUID() {
94 public IArtifactInfo getGeneratedArtifact() {
99 public java.util.List<IArtifactInfo> getRelatedArtifacts() {
104 public boolean equals(Object obj) {
105 if (!(obj instanceof TestArtifactInfoImpl)) {
107 } else if (obj == this) {
110 TestArtifactInfoImpl rhs = (TestArtifactInfoImpl) obj;
112 return new EqualsBuilder()
113 .append(artifactType, rhs.artifactType)
114 .append(artifactDescription, rhs.artifactDescription)
115 .append(artifactVersion, rhs.artifactVersion)
121 public int hashCode() {
122 return Objects.hash(this.artifactType, this.artifactDescription, this.artifactVersion);