1 package org.openecomp.sdc.generator.datatypes.tosca;
3 import org.openecomp.sdc.vendorsoftwareproduct.types.composition.Nic;
8 public class VspModelInfo {
9 private String releaseVendor;
10 //Map of component id and name
11 private Map<String, String> components;
12 //Map of part number and deployment flavor model
13 private Map<String, DeploymentFlavorModel> allowedFlavors;
14 //Map of component id and images
15 private Map<String, List<MultiFlavorVfcImage>> multiFlavorVfcImages;
16 //Map of component and ports (NICs)
17 private Map<String, List<Nic>> nics;
19 public String getReleaseVendor() {
23 public void setReleaseVendor(String releaseVendor) {
24 this.releaseVendor = releaseVendor;
27 public Map<String, String> getComponents() {
31 public void setComponents(Map<String, String> components) {
32 this.components = components;
35 public Map<String, DeploymentFlavorModel> getAllowedFlavors() {
36 return allowedFlavors;
39 public void setAllowedFlavors(Map<String, DeploymentFlavorModel> allowedFlavors) {
40 this.allowedFlavors = allowedFlavors;
43 public Map<String, List<MultiFlavorVfcImage>> getMultiFlavorVfcImages() {
44 return multiFlavorVfcImages;
47 public void setMultiFlavorVfcImages(Map<String, List<MultiFlavorVfcImage>> multiFlavorVfcImages) {
48 this.multiFlavorVfcImages = multiFlavorVfcImages;
51 public Map<String, List<Nic>> getNics() {
55 public void setNics(Map<String, List<Nic>> nics) {
60 public int hashCode() {
61 int result = releaseVendor != null ? releaseVendor.hashCode() : 0;
62 result = 31 * result + (components != null ? components.hashCode() : 0);
63 result = 31 * result + (allowedFlavors != null ? allowedFlavors.hashCode() : 0);
64 result = 31 * result + (multiFlavorVfcImages != null ? multiFlavorVfcImages.hashCode() : 0);
65 result = 31 * result + (nics != null ? nics.hashCode() : 0);
70 public String toString() {
71 return "VspModelInfo{"
72 + "releaseVendor='" + releaseVendor + '\''
73 + ", components=" + components
74 + ", allowedFlavors=" + allowedFlavors
75 + ", multiFlavorVfcImages=" + multiFlavorVfcImages
81 public boolean equals(Object obj) {
85 if (obj != null && getClass() != obj.getClass()) {
88 VspModelInfo other = (VspModelInfo) obj;
90 if (this.releaseVendor == null) {
91 if (other.releaseVendor != null) {
94 } else if (!releaseVendor.equals(other.releaseVendor)) {
97 if (this.components == null) {
98 if (other.components != null) {
101 } else if (!components.equals(other.components)) {
104 if (this.allowedFlavors == null) {
105 if (other.allowedFlavors != null) {
108 } else if (!allowedFlavors.equals(other.allowedFlavors)) {
111 if (this.multiFlavorVfcImages == null) {
112 if (other.multiFlavorVfcImages != null) {
115 } else if (!multiFlavorVfcImages.equals(other.multiFlavorVfcImages)) {
118 if (this.multiFlavorVfcImages == null) {
119 if (other.multiFlavorVfcImages != null) {
122 } else if (!multiFlavorVfcImages.equals(other.multiFlavorVfcImages)) {
125 if (this.nics == null) {
126 if (other.nics != null) {
129 } else if (!nics.equals(other.nics)) {