org.onap migration
[vid.git] / vid-app-common / src / main / java / org / onap / vid / mso / rest / RequestList.java
1 /*-
2  * ============LICENSE_START=======================================================
3  * VID
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
10  * 
11  *      http://www.apache.org/licenses/LICENSE-2.0
12  * 
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=========================================================
19  */
20
21 package org.onap.vid.mso.rest;
22
23 import java.util.HashMap;
24 import java.util.Map;
25
26 import javax.annotation.Generated;
27
28 import com.fasterxml.jackson.annotation.JsonAnyGetter;
29 import com.fasterxml.jackson.annotation.JsonAnySetter;
30 import com.fasterxml.jackson.annotation.JsonIgnore;
31 import com.fasterxml.jackson.annotation.JsonInclude;
32 import com.fasterxml.jackson.annotation.JsonPropertyOrder;
33
34 //import com.fasterxml.jackson.annotation.JsonInclude;
35 //import com.fasterxml.jackson.annotation.JsonProperty;
36 //import com.fasterxml.jackson.annotation.JsonPropertyOrder;
37 import org.apache.commons.lang.builder.EqualsBuilder;
38 import org.apache.commons.lang.builder.HashCodeBuilder;
39 import org.apache.commons.lang.builder.ToStringBuilder;
40 import java.util.List;
41
42 /**
43  * List of relatedModel structures that are related to a modelInfo being operated on.
44  */
45 @JsonInclude(JsonInclude.Include.NON_NULL)
46 @Generated("org.jsonschema2pojo")
47 @JsonPropertyOrder({
48     "finishTime",
49     "instanceIds",
50     "requestDetails",
51     "requestId",
52     "requestScope",
53     "requestStatus",
54     "requestType",
55     "startTime"
56 })
57
58 public class RequestList {
59     
60     /** The request list. */
61     private List<RequestWrapper> requestList;
62     
63     /** The additional properties. */
64     @JsonIgnore
65     private Map<String, Object> additionalProperties = new HashMap<String, Object>();
66
67     /**
68      * (Required).
69      *
70      * @return     The RelatedModel List
71      */
72     public List<RequestWrapper> getRequestList() {
73         return requestList;
74     }
75
76     /**
77      * Sets the request list.
78      *
79      * @param l the new request list
80      */
81     public void setRequestList(List<RequestWrapper> l) {
82         this.requestList = l;
83     }
84
85     /* (non-Javadoc)
86      * @see java.lang.Object#toString()
87      */
88     @Override
89     public String toString() {
90         return ToStringBuilder.reflectionToString(this);
91     }
92
93     /**
94      * Gets the additional properties.
95      *
96      * @return the additional properties
97      */
98     @JsonAnyGetter
99     public Map<String, Object> getAdditionalProperties() {
100         return this.additionalProperties;
101     }
102
103     /**
104      * Sets the additional property.
105      *
106      * @param name the name
107      * @param value the value
108      */
109     @JsonAnySetter
110     public void setAdditionalProperty(String name, Object value) {
111         this.additionalProperties.put(name, value);
112     }
113
114     /* (non-Javadoc)
115      * @see java.lang.Object#hashCode()
116      */
117     @Override
118     public int hashCode() {
119         return new HashCodeBuilder().append(getRequestList()).append(additionalProperties).toHashCode();
120     }
121
122     /* (non-Javadoc)
123      * @see java.lang.Object#equals(java.lang.Object)
124      */
125     @Override
126     public boolean equals(Object other) {
127         if (other == this) {
128             return true;
129         }
130         if ((other instanceof RequestList) == false) {
131             return false;
132         }
133         RequestList rhs = ((RequestList) other);
134         return new EqualsBuilder().append(getRequestList(), rhs.getRequestList()).append(additionalProperties, rhs.additionalProperties).isEquals();
135     }
136
137 }