2 * ============LICENSE_START=======================================================
4 * ================================================================================
5 * Copyright © 2017-2018 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
11 * http://www.apache.org/licenses/LICENSE-2.0
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=========================================================
21 package org.onap.aai.schemaservice.versions;
23 import com.google.gson.annotations.SerializedName;
25 import java.util.List;
26 import java.util.Objects;
28 public class Version {
30 private List<String> versions;
32 @SerializedName("edge-version")
33 private String edgeVersion;
34 @SerializedName("default-version")
35 private String defaultVersion;
36 @SerializedName("depth-version")
37 private String depthVersion;
38 @SerializedName("app-root-version")
39 private String appRootVersion;
40 @SerializedName("related-link-version")
41 private String relatedLinkVersion;
42 @SerializedName("namespace-change-version")
43 private String namespaceChangeVersion;
45 public List<String> getVersions() {
49 public void setVersions(List<String> versions) {
50 this.versions = versions;
53 public String getEdgeVersion() {
57 public void setEdgeVersion(String edgeVersion) {
58 this.edgeVersion = edgeVersion;
61 public String getDefaultVersion() {
62 return defaultVersion;
65 public void setDefaultVersion(String defaultVersion) {
66 this.defaultVersion = defaultVersion;
69 public String getDepthVersion() {
73 public void setDepthVersion(String depthVersion) {
74 this.depthVersion = depthVersion;
77 public String getAppRootVersion() {
78 return appRootVersion;
81 public void setAppRootVersion(String appRootVersion) {
82 this.appRootVersion = appRootVersion;
85 public String getRelatedLinkVersion() {
86 return relatedLinkVersion;
89 public void setRelatedLinkVersion(String relatedLinkVersion) {
90 this.relatedLinkVersion = relatedLinkVersion;
93 public String getNamespaceChangeVersion() {
94 return namespaceChangeVersion;
97 public void setNamespaceChangeVersion(String namespaceChangeVersion) {
98 this.namespaceChangeVersion = namespaceChangeVersion;
102 public boolean equals(Object o) {
105 if (o == null || getClass() != o.getClass())
107 Version that = (Version) o;
108 return Objects.equals(versions, that.versions)
109 && Objects.equals(edgeVersion, that.edgeVersion)
110 && Objects.equals(defaultVersion, that.defaultVersion)
111 && Objects.equals(depthVersion, that.depthVersion)
112 && Objects.equals(appRootVersion, that.appRootVersion)
113 && Objects.equals(relatedLinkVersion, that.relatedLinkVersion)
114 && Objects.equals(namespaceChangeVersion, that.namespaceChangeVersion);
118 public int hashCode() {
119 return Objects.hash(versions, edgeVersion, defaultVersion, depthVersion, appRootVersion,
120 relatedLinkVersion, namespaceChangeVersion);
124 public String toString() {
125 return "Version{" + "versions=" + versions + ", edgeVersion='" + edgeVersion + '\''
126 + ", defaultVersion='" + defaultVersion + '\'' + ", depthVersion='" + depthVersion
127 + '\'' + ", appRootVersion='" + appRootVersion + '\'' + ", relatedLinkVersion='"
128 + relatedLinkVersion + '\'' + ", namespaceChangeVersion='" + namespaceChangeVersion