Add WorkflowSpecification Beans for APIH
[so.git] / mso-api-handlers / mso-api-handler-infra / src / main / java / org / onap / so / apihandlerinfra / workflowspecificationbeans / WorkflowInputParameter.java
1 /*-
2  * ============LICENSE_START=======================================================
3  * ONAP - SO
4  * ================================================================================
5  * Copyright (C) 2019 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 package org.onap.so.apihandlerinfra.workflowspecificationbeans;
21
22 import java.util.List;
23 import com.fasterxml.jackson.annotation.JsonInclude;
24 import com.fasterxml.jackson.annotation.JsonProperty;
25 import com.fasterxml.jackson.annotation.JsonPropertyOrder;
26
27 @JsonInclude(JsonInclude.Include.NON_NULL)
28 @JsonPropertyOrder({
29     "label",
30     "inputType",
31     "required",
32     "validation",
33     "soFieldName",
34     "soPayloadLocation"
35 })
36 public class WorkflowInputParameter {
37
38     @JsonProperty("label")
39     private String label;
40     @JsonProperty("inputType")
41     private String inputType;
42     @JsonProperty("required")
43     private Boolean required;
44     @JsonProperty("validation")
45     private List<Validation> validation = null;
46     @JsonProperty("soFieldName")
47     private String soFieldName;
48     @JsonProperty("soPayloadLocation")
49     private String soPayloadLocation;
50
51     /**
52      * No args constructor for use in serialization
53      * 
54      */
55     public WorkflowInputParameter() {
56     }
57
58     /**
59      * 
60      * @param validation
61      * @param inputType
62      * @param soPayloadLocation
63      * @param label
64      * @param required
65      * @param soFieldName
66      */
67     public WorkflowInputParameter(String label, String inputType, Boolean required, List<Validation> validation, String soFieldName, String soPayloadLocation) {
68         super();
69         this.label = label;
70         this.inputType = inputType;
71         this.required = required;
72         this.validation = validation;
73         this.soFieldName = soFieldName;
74         this.soPayloadLocation = soPayloadLocation;
75     }
76
77     @JsonProperty("label")
78     public String getLabel() {
79         return label;
80     }
81
82     @JsonProperty("label")
83     public void setLabel(String label) {
84         this.label = label;
85     }
86
87     public WorkflowInputParameter withLabel(String label) {
88         this.label = label;
89         return this;
90     }
91
92     @JsonProperty("inputType")
93     public String getInputType() {
94         return inputType;
95     }
96
97     @JsonProperty("inputType")
98     public void setInputType(String inputType) {
99         this.inputType = inputType;
100     }
101
102     public WorkflowInputParameter withInputType(String inputType) {
103         this.inputType = inputType;
104         return this;
105     }
106
107     @JsonProperty("required")
108     public Boolean getRequired() {
109         return required;
110     }
111
112     @JsonProperty("required")
113     public void setRequired(Boolean required) {
114         this.required = required;
115     }
116
117     public WorkflowInputParameter withRequired(Boolean required) {
118         this.required = required;
119         return this;
120     }
121
122     @JsonProperty("validation")
123     public List<Validation> getValidation() {
124         return validation;
125     }
126
127     @JsonProperty("validation")
128     public void setValidation(List<Validation> validation) {
129         this.validation = validation;
130     }
131
132     public WorkflowInputParameter withValidation(List<Validation> validation) {
133         this.validation = validation;
134         return this;
135     }
136
137     @JsonProperty("soFieldName")
138     public String getSoFieldName() {
139         return soFieldName;
140     }
141
142     @JsonProperty("soFieldName")
143     public void setSoFieldName(String soFieldName) {
144         this.soFieldName = soFieldName;
145     }
146
147     public WorkflowInputParameter withSoFieldName(String soFieldName) {
148         this.soFieldName = soFieldName;
149         return this;
150     }
151
152     @JsonProperty("soPayloadLocation")
153     public String getSoPayloadLocation() {
154         return soPayloadLocation;
155     }
156
157     @JsonProperty("soPayloadLocation")
158     public void setSoPayloadLocation(String soPayloadLocation) {
159         this.soPayloadLocation = soPayloadLocation;
160     }
161
162     public WorkflowInputParameter withSoPayloadLocation(String soPayloadLocation) {
163         this.soPayloadLocation = soPayloadLocation;
164         return this;
165     }
166
167 }