Interface definition
[sdc.git] / common-be / src / main / java / org / openecomp / sdc / be / datatypes / elements / WorkflowOperationDataDefinition.java
1 /*
2  * Copyright © 2016-2018 European Support Limited
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16
17 package org.openecomp.sdc.be.datatypes.elements;
18
19 import static org.openecomp.sdc.be.datatypes.enums.JsonPresentationFields.DESCRIPTION;
20 import static org.openecomp.sdc.be.datatypes.enums.JsonPresentationFields.TOSCA_RESOURCE_NAME;
21 import static org.openecomp.sdc.be.datatypes.enums.JsonPresentationFields.UNIQUE_ID;
22 import static org.openecomp.sdc.be.datatypes.enums.JsonPresentationFields.WO_INPUT_PARAMETERS;
23 import static org.openecomp.sdc.be.datatypes.enums.JsonPresentationFields.WO_OUTPUT_PARAMETERS;
24 import static org.openecomp.sdc.be.datatypes.enums.JsonPresentationFields.WO_TYPE;
25
26
27 import java.io.Serializable;
28 import org.openecomp.sdc.be.datatypes.tosca.ToscaDataDefinition;
29
30 public class WorkflowOperationDataDefinition extends ToscaDataDefinition implements Serializable {
31
32     public WorkflowOperationDataDefinition() {
33         super();
34     }
35
36     public WorkflowOperationDataDefinition(WorkflowOperationDataDefinition wodd) {
37         super();
38         setUniqueId(wodd.getUniqueId());
39         setInputParams(wodd.getInputParams());
40         setOutputParams(wodd.getOutputParams());
41         setDescription(wodd.getDescription());
42         setToscaResourceName(wodd.getToscaResourceName());
43         setType(wodd.getType());
44     }
45
46     public ListDataDefinition<WorkflowOperationParamDataDefinition> getInputParams() {
47         return (ListDataDefinition<WorkflowOperationParamDataDefinition>) getToscaPresentationValue(WO_INPUT_PARAMETERS);
48     }
49
50     public void setInputParams(ListDataDefinition<WorkflowOperationParamDataDefinition> pathElements) {
51         setToscaPresentationValue(WO_INPUT_PARAMETERS, pathElements);
52     }
53     public ListDataDefinition<WorkflowOperationParamDataDefinition> getOutputParams() {
54         return (ListDataDefinition<WorkflowOperationParamDataDefinition>) getToscaPresentationValue(WO_OUTPUT_PARAMETERS);
55     }
56
57     public void setOutputParams(ListDataDefinition<WorkflowOperationParamDataDefinition> pathElements) {
58         setToscaPresentationValue(WO_OUTPUT_PARAMETERS, pathElements);
59     }
60     public String getUniqueId() {
61         return (String) getToscaPresentationValue(UNIQUE_ID);
62     }
63
64     public void setUniqueId(String uid) {
65         setToscaPresentationValue(UNIQUE_ID, uid);
66     }
67
68     public String getDescription() {
69         return (String) getToscaPresentationValue(DESCRIPTION);
70     }
71
72     public void setDescription(String description) {
73         setToscaPresentationValue(DESCRIPTION, description);
74     }
75     public String getType() {
76         return (String) getToscaPresentationValue(WO_TYPE);
77     }
78
79     public void setType(String description) {
80         setToscaPresentationValue(WO_TYPE, description);
81     }
82     public String getToscaResourceName() {
83            return (String) getToscaPresentationValue(TOSCA_RESOURCE_NAME);
84     }
85
86     public void setToscaResourceName(String toscaResourceName) {
87         setToscaPresentationValue(TOSCA_RESOURCE_NAME, toscaResourceName);
88     }
89 }