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.db.request.beans;
23 import java.io.Serializable;
24 import java.util.Objects;
25 import com.openpojo.business.annotation.BusinessKey;
26 import org.apache.commons.lang3.builder.ToStringBuilder;
28 public class ResourceOperationStatusId implements Serializable {
30 private static final long serialVersionUID = -7425019928845751157L;
33 private String serviceId;
35 private String operationId;
37 private String resourceTemplateUUID;
39 public ResourceOperationStatusId() {
43 public ResourceOperationStatusId(String serviceId, String operationId, String resourceTemplateUUID) {
44 this.serviceId = serviceId;
45 this.operationId = operationId;
46 this.resourceTemplateUUID = resourceTemplateUUID;
49 public String getServiceId() {
53 public void setServiceId(String serviceId) {
54 this.serviceId = serviceId;
57 public String getOperationId() {
61 public void setOperationId(String operationId) {
62 this.operationId = operationId;
65 public String getResourceTemplateUUID() {
66 return resourceTemplateUUID;
69 public void setResourceTemplateUUID(String resourceTemplateUUID) {
70 this.resourceTemplateUUID = resourceTemplateUUID;
74 public boolean equals(final Object other) {
78 if (!(other instanceof ResourceOperationStatusId)) {
81 ResourceOperationStatusId castOther = (ResourceOperationStatusId) other;
82 return Objects.equals(this.getServiceId(), castOther.getServiceId())
83 && Objects.equals(this.getOperationId(), castOther.getOperationId())
84 && Objects.equals(this.getResourceTemplateUUID(), castOther.getResourceTemplateUUID());
88 public int hashCode() {
89 return Objects.hash(this.getServiceId(), this.getOperationId(), this.getResourceTemplateUUID());
93 public String toString() {
94 return new ToStringBuilder(this).append("serviceId", getServiceId()).append("operationId", getOperationId())
95 .append("resourceTemplateUUID", getResourceTemplateUUID()).toString();