2476b07bd1ca9de94bf2a08ec53731cbcb535a1d
[multicloud/framework.git] / artifactbroker / plugins / reception-plugins / src / main / java / org / onap / policy / distribution / reception / handling / sdc / SdcReceptionHandlerConfigurationParameterBuilder.java
1 /*-
2  * ============LICENSE_START=======================================================
3  *  Copyright (C) 2018 Ericsson. All rights reserved.
4  * ================================================================================
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  *      http://www.apache.org/licenses/LICENSE-2.0
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  * SPDX-License-Identifier: Apache-2.0
18  * ============LICENSE_END=========================================================
19  */
20
21 package org.onap.policy.distribution.reception.handling.sdc;
22
23 import java.util.List;
24
25 /**
26  * This class builds an instance of {@link SdcReceptionHandlerConfigurationParameterGroup} class.
27  *
28  * @author Ram Krishna Verma (ram.krishna.verma@ericsson.com)
29  */
30 public class SdcReceptionHandlerConfigurationParameterBuilder {
31
32     private boolean activeserverTlsAuth;
33     private boolean filterinEmptyResources;
34     private boolean useHttpsWithDmaap;
35     private boolean useHttpsWithSDC;
36     private int pollingTimeout;
37     private int pollingInterval;
38     private String user;
39     private String password;
40     private String consumerId;
41     private String consumerGroup;
42     private String asdcAddress;
43     private String environmentName;
44     private String keystorePath;
45     private String keystorePassword;
46     private int httpsproxyPort;
47     private int httpproxyPort;
48     private String httpsproxyHost;
49     private String httpproxyHost;
50     private List<String> messageBusAddress;
51     private List<String> artifactTypes;
52     private int retryDelay;
53
54     /**
55      * Set activeserverTlsAuth to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
56      *
57      * @param activeserverTlsAuth the activeserverTlsAuth
58      */
59     public SdcReceptionHandlerConfigurationParameterBuilder setActiveserverTlsAuth(final boolean activeserverTlsAuth) {
60         this.activeserverTlsAuth = activeserverTlsAuth;
61         return this;
62     }
63
64     /**
65      * Set filterinEmptyResources to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
66      *
67      * @param filterinEmptyResources the filterinEmptyResources
68      */
69     public SdcReceptionHandlerConfigurationParameterBuilder setFilterinEmptyResources(
70             final boolean filterinEmptyResources) {
71         this.filterinEmptyResources = filterinEmptyResources;
72         return this;
73     }
74
75     /**
76      * Set useHttpsWithDmaap to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
77      *
78      * @param useHttpsWithDmaap the useHttpsWithDmaap
79      */
80     public SdcReceptionHandlerConfigurationParameterBuilder setUseHttpsWithDmaap(final Boolean useHttpsWithDmaap) {
81         this.useHttpsWithDmaap = useHttpsWithDmaap;
82         return this;
83     }
84
85     /**
86      * Set pollingInterval to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
87      *
88      * @param pollingInterval the pollingInterval
89      */
90     public SdcReceptionHandlerConfigurationParameterBuilder setPollingInterval(final int pollingInterval) {
91         this.pollingInterval = pollingInterval;
92         return this;
93     }
94
95     /**
96      * Set pollingTimeout to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
97      *
98      * @param pollingTimeout the pollingTimeout
99      */
100     public SdcReceptionHandlerConfigurationParameterBuilder setPollingTimeout(final int pollingTimeout) {
101         this.pollingTimeout = pollingTimeout;
102         return this;
103     }
104
105     /**
106      * Set asdcAddress to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
107      *
108      * @param asdcAddress the asdcAddress
109      */
110     public SdcReceptionHandlerConfigurationParameterBuilder setAsdcAddress(final String asdcAddress) {
111         this.asdcAddress = asdcAddress;
112         return this;
113     }
114
115     /**
116      * Set user to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
117      *
118      * @param user the user
119      */
120     public SdcReceptionHandlerConfigurationParameterBuilder setUser(final String user) {
121         this.user = user;
122         return this;
123     }
124
125     /**
126      * Set password to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
127      *
128      * @param password the password
129      */
130     public SdcReceptionHandlerConfigurationParameterBuilder setPassword(final String password) {
131         this.password = password;
132         return this;
133     }
134
135     /**
136      * Set consumerId to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
137      *
138      * @param consumerId the consumerId
139      */
140     public SdcReceptionHandlerConfigurationParameterBuilder setConsumerId(final String consumerId) {
141         this.consumerId = consumerId;
142         return this;
143     }
144
145     /**
146      * Set consumerGroup to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
147      *
148      * @param consumerGroup the consumerGroup
149      */
150     public SdcReceptionHandlerConfigurationParameterBuilder setConsumerGroup(final String consumerGroup) {
151         this.consumerGroup = consumerGroup;
152         return this;
153     }
154
155     /**
156      * Set environmentName to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
157      *
158      * @param environmentName the environmentName
159      */
160     public SdcReceptionHandlerConfigurationParameterBuilder setEnvironmentName(final String environmentName) {
161         this.environmentName = environmentName;
162         return this;
163     }
164
165     /**
166      * Set keystorePath to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
167      *
168      * @param keystorePath the keystorePath
169      */
170     public SdcReceptionHandlerConfigurationParameterBuilder setKeystorePath(final String keystorePath) {
171         this.keystorePath = keystorePath;
172         return this;
173     }
174
175     /**
176      * Set keystorePassword to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
177      *
178      * @param keystorePassword the keystorePassword
179      */
180     public SdcReceptionHandlerConfigurationParameterBuilder setKeystorePassword(final String keystorePassword) {
181         this.keystorePassword = keystorePassword;
182         return this;
183     }
184
185     /**
186      * Set messageBusAddress to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
187      *
188      * @param messageBusAddress the messageBusAddress
189      */
190     public SdcReceptionHandlerConfigurationParameterBuilder setMessageBusAddress(final List<String> messageBusAddress) {
191         this.messageBusAddress = messageBusAddress;
192         return this;
193     }
194
195     /**
196      * Set artifactTypes to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
197      *
198      * @param artifactTypes the artifactTypes
199      */
200     public SdcReceptionHandlerConfigurationParameterBuilder setArtifactTypes(final List<String> artifactTypes) {
201         this.artifactTypes = artifactTypes;
202         return this;
203     }
204
205     /**
206      * Set retryDelay to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
207      *
208      * @param retryDelay the retryDelay
209      */
210     public SdcReceptionHandlerConfigurationParameterBuilder setRetryDelay(final int retryDelay) {
211         this.retryDelay = retryDelay;
212         return this;
213     }
214
215     /**
216      * Returns the active server TlsAuth of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
217      *
218      * @return the activeserverTlsAuth
219      */
220     public boolean isActiveserverTlsAuth() {
221         return activeserverTlsAuth;
222     }
223
224     /**
225      * Returns the isFilterinEmptyResources flag of this {@link SdcReceptionHandlerConfigurationParameterBuilder}
226      * instance.
227      *
228      * @return the isFilterinEmptyResources
229      */
230     public boolean isFilterinEmptyResources() {
231         return filterinEmptyResources;
232     }
233
234     /**
235      * Returns the isUseHttpsWithDmaap flag of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
236      *
237      * @return the isUseHttpsWithDmaap
238      */
239     public Boolean getIsUseHttpsWithDmaap() {
240         return useHttpsWithDmaap;
241     }
242
243     /**
244      * Returns the isUseHttpsWithSDC flag of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
245      *
246      * @return the isUseHttpsWithSDC
247      */
248     public Boolean getIsUseHttpsWithSDC() {
249         return useHttpsWithSDC;
250     }
251
252     /**
253      * Returns the polling interval of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
254      *
255      * @return the pollingInterval
256      */
257     public int getPollingInterval() {
258         return pollingInterval;
259     }
260
261     /**
262      * Returns the polling timeout of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
263      *
264      * @return the pollingTimeout
265      */
266     public int getPollingTimeout() {
267         return pollingTimeout;
268     }
269
270     /**
271      * Returns the asdc address of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
272      *
273      * @return the asdcAddress
274      */
275     public String getAsdcAddress() {
276         return asdcAddress;
277     }
278
279     /**
280      * Returns the user of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
281      *
282      * @return the user
283      */
284     public String getUser() {
285         return user;
286     }
287
288     /**
289      * Returns the password of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
290      *
291      * @return the password
292      */
293     public String getPassword() {
294         return password;
295     }
296
297     /**
298      * Returns the consumer id of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
299      *
300      * @return the consumerId
301      */
302     public String getConsumerId() {
303         return consumerId;
304     }
305
306     /**
307      * Returns the consumer group of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
308      *
309      * @return the consumerGroup
310      */
311     public String getConsumerGroup() {
312         return consumerGroup;
313     }
314
315     /**
316      * Returns the environment name of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
317      *
318      * @return the environmentName
319      */
320     public String getEnvironmentName() {
321         return environmentName;
322     }
323
324     /**
325      * Returns the keystore path of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
326      *
327      * @return the keystorePath
328      */
329     public String getKeystorePath() {
330         return keystorePath;
331     }
332
333     /**
334      * Returns the keystore password of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
335      *
336      * @return the keystorePassword
337      */
338     public String getKeystorePassword() {
339         return keystorePassword;
340     }
341
342     /**
343      * Returns the message bus address of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
344      *
345      * @return the messageBusAddress
346      */
347     public List<String> getMessageBusAddress() {
348         return messageBusAddress;
349     }
350
351     /**
352      * Returns the artifact types of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
353      *
354      * @return the artifactTypes
355      */
356     public List<String> getArtifactTypes() {
357         return artifactTypes;
358     }
359
360     /**
361      * Returns the retryDelay of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
362      *
363      * @return the retryDelay
364      */
365     public int getRetryDelay() {
366         return retryDelay;
367     }
368     /**
369      * Returns the https proxy port of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
370      *
371      * @return the httpsproxyPort
372      */
373     public int getHttpsProxyPort() {
374         return httpsproxyPort;
375     }
376     /**
377      * Returns the https proxy host of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
378      *
379      * @return the httpsproxyHost
380      */
381     public String getHttpsProxyHost() {
382         return httpsproxyHost;
383     }
384         /**
385      * Returns the http proxy port of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
386      *
387      * @return the httpproxyPort
388      */
389     public int getHttpProxyPort() {
390         return httpproxyPort;
391     }
392     /**
393      * Returns the http proxy host of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
394      *
395      * @return the httpsproxyHost
396      */
397     public String getHttpProxyHost() {
398         return httpproxyHost;
399     }
400 }
401
402