014407e25831f0e025a342689fe4f5c289717845
[aai/sparky-be.git] / src / main / java / org / onap / aai / sparky / search / filters / config / UiFilterConfig.java
1 /**
2  * ============LICENSE_START=======================================================
3  * org.onap.aai
4  * ================================================================================
5  * Copyright © 2017 AT&T Intellectual Property. All rights reserved.
6  * Copyright © 2017 Amdocs
7  * ================================================================================
8  * Licensed under the Apache License, Version 2.0 (the "License");
9  * you may not use this file except in compliance with the License.
10  * You may obtain a copy of the License at
11  *
12  *       http://www.apache.org/licenses/LICENSE-2.0
13  *
14  * Unless required by applicable law or agreed to in writing, software
15  * distributed under the License is distributed on an "AS IS" BASIS,
16  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17  * See the License for the specific language governing permissions and
18  * limitations under the License.
19  * ============LICENSE_END=========================================================
20  *
21  * ECOMP is a trademark and service mark of AT&T Intellectual Property.
22  */
23 package org.onap.aai.sparky.search.filters.config;
24
25 import java.util.List;
26
27 import com.att.aft.dme2.internal.jackson.annotate.JsonCreator;
28 import com.fasterxml.jackson.annotation.JsonInclude;
29 import com.fasterxml.jackson.annotation.JsonInclude.Include;
30 import com.fasterxml.jackson.annotation.JsonProperty;
31
32 @JsonInclude(Include.NON_NULL)
33 public class UiFilterConfig {
34
35   @JsonProperty("filterId")
36   private String filterId;
37
38   @JsonProperty("filterName")
39   private String filterName;
40
41   @JsonProperty("displayName")
42   private String displayName;
43
44   @JsonProperty("dataType")
45   private String dataType;
46
47   @JsonProperty("multiSelect")
48   private String multiSelect;
49
50   @JsonProperty("watermark")
51   private String watermark;
52
53   @JsonProperty("defaultValue")
54   private UiFilterOptionsValuesConfig defaultValue;
55
56   @JsonProperty("optionsType")
57   private String optionsType;
58
59   @JsonProperty("optionsValues")
60   private List<UiFilterOptionsValuesConfig> optionsValues;
61
62   @JsonProperty("dataSource")
63   private UiFilterDataSourceConfig dataSource = new UiFilterDataSourceConfig();
64
65   @JsonCreator
66   public UiFilterConfig(@JsonProperty("filterId") final String filterId,
67       @JsonProperty("filterName") final String filterName,
68       @JsonProperty("displayName") final String displayName,
69       @JsonProperty("dataType") final String dataType,
70       @JsonProperty("multiSelect") final String multiSelect,
71       @JsonProperty("watermark") final String watermark,
72       @JsonProperty("defaultValue") final UiFilterOptionsValuesConfig defaultValue,
73       @JsonProperty("optionsType") final String optionsType,
74       @JsonProperty("optionsValues") final List<UiFilterOptionsValuesConfig> optionsValues,
75       @JsonProperty("dataSource") final UiFilterDataSourceConfig dataSource) {
76     this.filterId = filterId;
77     this.filterName = filterName;
78     this.displayName = displayName;
79     this.dataType = dataType;
80     this.multiSelect = multiSelect;
81     this.watermark = watermark;
82     this.defaultValue = defaultValue;
83     this.optionsType = optionsType;
84     this.optionsValues = optionsValues;
85     this.dataSource = dataSource;
86   }
87
88   @JsonProperty("filterId")
89   public String getFilterId() {
90     return filterId;
91   }
92
93   public void setFilterId(String filterId) {
94     this.filterId = filterId;
95   }
96
97   @JsonProperty("filterName")
98   public String getFilterName() {
99     return filterName;
100   }
101
102   public void setFilterName(String filterName) {
103     this.filterName = filterName;
104   }
105
106   @JsonProperty("displayName")
107   public String getDisplayName() {
108     return displayName;
109   }
110
111   public void setDisplayName(String displayName) {
112     this.displayName = displayName;
113   }
114
115   @JsonProperty("dataType")
116   public String getDataType() {
117     return dataType;
118   }
119
120   public void setDataType(String dataType) {
121     this.dataType = dataType;
122   }
123
124   @JsonProperty("multiSelect")
125   public String getMultiSelect() {
126     return multiSelect;
127   }
128
129   public void setMultiSelect(String multiSelect) {
130     this.multiSelect = multiSelect;
131   }
132
133   @JsonProperty("watermark")
134   public String getWatermark() {
135     return watermark;
136   }
137
138   public void setWatermark(String watermark) {
139     this.watermark = watermark;
140   }
141
142   @JsonProperty("defaultValue")
143   public UiFilterOptionsValuesConfig getDefaultValue() {
144     return defaultValue;
145   }
146
147   public void setDefaultValue(UiFilterOptionsValuesConfig defaultValue) {
148     this.defaultValue = defaultValue;
149   }
150
151   @JsonProperty("optionsType")
152   public String getOptionsType() {
153     return optionsType;
154   }
155
156   public void setOptionsType(String optionsType) {
157     this.optionsType = optionsType;
158   }
159
160   @JsonProperty("optionsValues")
161   public List<UiFilterOptionsValuesConfig> getOptionsValues() {
162     return optionsValues;
163   }
164
165   public void setOptionsValues(List<UiFilterOptionsValuesConfig> optionsValues) {
166     this.optionsValues = optionsValues;
167   }
168
169   @JsonProperty("dataSource")
170   public UiFilterDataSourceConfig getDataSource() {
171     return dataSource;
172   }
173
174   public void setDataSource(UiFilterDataSourceConfig dataSource) {
175     this.dataSource = dataSource;
176   }
177
178   @Override
179   public String toString() {
180     return "UiFilterConfig [filterId=" + filterId + ", filterName=" + filterName + ", displayName="
181         + displayName + ", dataType=" + dataType + ", multiSelect=" + multiSelect + ", watermark="
182         + watermark + ", optionsType=" + optionsType + ", optionsValues=" + optionsValues
183         + ", dataSource=" + dataSource + "]";
184   }
185 }
186