2 * ============LICENSE_START=======================================================
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
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.so.client.aai.objects;
23 import org.onap.so.client.aai.AAIObjectType;
24 import org.onap.so.client.aai.entities.AAIEntityObject;
25 import org.onap.so.client.aai.entities.uri.AAIResourceUri;
26 import org.onap.so.client.aai.entities.uri.AAIUriFactory;
28 import com.fasterxml.jackson.annotation.JsonProperty;
30 public class AAIServiceInstance implements AAIEntityObject {
32 @JsonProperty("service-instance-id")
33 private String serviceInstanceId;
34 @JsonProperty("service-instance-name")
35 private String serviceInstanceName;
36 @JsonProperty("service-type")
37 private String serviceType;
38 @JsonProperty("service-role")
39 private String serviceRole;
40 @JsonProperty("orchestration-status")
41 private String oStatus;
42 @JsonProperty("model-invariant-id")
43 private String modelInvariantUuid;
44 @JsonProperty("model-version-id")
45 private String modelUuid;
46 @JsonProperty("environment-context")
47 private String environmentContext;
48 @JsonProperty("workload-context")
49 private String workloadContext;
51 public String getServiceInstanceName() {
52 return serviceInstanceName;
55 public void setServiceInstanceName(String serviceInstanceName) {
56 this.serviceInstanceName = serviceInstanceName;
59 public String getServiceType() {
63 public void setServiceType(String serviceType) {
64 this.serviceType = serviceType;
67 public String getServiceRole() {
71 public void setServiceRole(String serviceRole) {
72 this.serviceRole = serviceRole;
75 public String getoStatus() {
79 public void setoStatus(String oStatus) {
80 this.oStatus = oStatus;
83 public String getModelInvariantUuid() {
84 return modelInvariantUuid;
87 public void setModelInvariantUuid(String modelInvariantUuid) {
88 this.modelInvariantUuid = modelInvariantUuid;
91 public String getModelUuid() {
95 public void setModelUuid(String modelUuid) {
96 this.modelUuid = modelUuid;
99 public String getEnvironmentContext() {
100 return environmentContext;
103 public void setEnvironmentContext(String environmentContext) {
104 this.environmentContext = environmentContext;
107 public String getWorkloadContext() {
108 return workloadContext;
111 public void setWorkloadContext(String workloadContext) {
112 this.workloadContext = workloadContext;
115 public String getServiceInstanceId() {
116 return serviceInstanceId;
119 public void setServiceInstanceId(String serviceInstanceId) {
120 this.serviceInstanceId = serviceInstanceId;
123 public AAIServiceInstance withServiceInstance(String serviceInstanceId) {
124 this.setServiceInstanceId(serviceInstanceId);
129 public AAIResourceUri getUri() {
130 AAIResourceUri uri = AAIUriFactory.createResourceUri(AAIObjectType.SERVICE_INSTANCE, this.serviceInstanceId);
134 public String toString() {
135 return "AAIServiceInstance [serviceInstanceId=" + serviceInstanceId + ", serviceInstanceName="
136 + serviceInstanceName + ", serviceType=" + serviceType + ", serviceRole=" + serviceRole + ", oStatus="
137 + oStatus + ", modelInvariantUuid=" + modelInvariantUuid + ", modelUuid=" + modelUuid
138 + ", environmentContext=" + environmentContext + ", workloadContext=" + workloadContext + "]";