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
9 * http://www.apache.org/licenses/LICENSE-2.0
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.
17 * SPDX-License-Identifier: Apache-2.0
18 * ============LICENSE_END=========================================================
21 package org.onap.policy.distribution.reception.handling.sdc;
23 import java.util.List;
26 * This class builds an instance of {@link SdcReceptionHandlerConfigurationParameterGroup} class.
28 * @author Ram Krishna Verma (ram.krishna.verma@ericsson.com)
30 public class SdcReceptionHandlerConfigurationParameterBuilder {
32 private boolean activeserverTlsAuth;
33 private boolean filterinEmptyResources;
34 private boolean useHttpsWithDmaap;
35 private boolean useHttpsWithSDC;
36 private int pollingTimeout;
37 private int pollingInterval;
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;
55 * Set activeserverTlsAuth to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
57 * @param activeserverTlsAuth the activeserverTlsAuth
59 public SdcReceptionHandlerConfigurationParameterBuilder setActiveserverTlsAuth(final boolean activeserverTlsAuth) {
60 this.activeserverTlsAuth = activeserverTlsAuth;
65 * Set filterinEmptyResources to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
67 * @param filterinEmptyResources the filterinEmptyResources
69 public SdcReceptionHandlerConfigurationParameterBuilder setFilterinEmptyResources(
70 final boolean filterinEmptyResources) {
71 this.filterinEmptyResources = filterinEmptyResources;
76 * Set useHttpsWithDmaap to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
78 * @param useHttpsWithDmaap the useHttpsWithDmaap
80 public SdcReceptionHandlerConfigurationParameterBuilder setUseHttpsWithDmaap(final Boolean useHttpsWithDmaap) {
81 this.useHttpsWithDmaap = useHttpsWithDmaap;
86 * Set pollingInterval to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
88 * @param pollingInterval the pollingInterval
90 public SdcReceptionHandlerConfigurationParameterBuilder setPollingInterval(final int pollingInterval) {
91 this.pollingInterval = pollingInterval;
96 * Set pollingTimeout to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
98 * @param pollingTimeout the pollingTimeout
100 public SdcReceptionHandlerConfigurationParameterBuilder setPollingTimeout(final int pollingTimeout) {
101 this.pollingTimeout = pollingTimeout;
106 * Set asdcAddress to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
108 * @param asdcAddress the asdcAddress
110 public SdcReceptionHandlerConfigurationParameterBuilder setAsdcAddress(final String asdcAddress) {
111 this.asdcAddress = asdcAddress;
116 * Set user to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
118 * @param user the user
120 public SdcReceptionHandlerConfigurationParameterBuilder setUser(final String user) {
126 * Set password to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
128 * @param password the password
130 public SdcReceptionHandlerConfigurationParameterBuilder setPassword(final String password) {
131 this.password = password;
136 * Set consumerId to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
138 * @param consumerId the consumerId
140 public SdcReceptionHandlerConfigurationParameterBuilder setConsumerId(final String consumerId) {
141 this.consumerId = consumerId;
146 * Set consumerGroup to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
148 * @param consumerGroup the consumerGroup
150 public SdcReceptionHandlerConfigurationParameterBuilder setConsumerGroup(final String consumerGroup) {
151 this.consumerGroup = consumerGroup;
156 * Set environmentName to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
158 * @param environmentName the environmentName
160 public SdcReceptionHandlerConfigurationParameterBuilder setEnvironmentName(final String environmentName) {
161 this.environmentName = environmentName;
166 * Set keystorePath to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
168 * @param keystorePath the keystorePath
170 public SdcReceptionHandlerConfigurationParameterBuilder setKeystorePath(final String keystorePath) {
171 this.keystorePath = keystorePath;
176 * Set keystorePassword to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
178 * @param keystorePassword the keystorePassword
180 public SdcReceptionHandlerConfigurationParameterBuilder setKeystorePassword(final String keystorePassword) {
181 this.keystorePassword = keystorePassword;
186 * Set messageBusAddress to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
188 * @param messageBusAddress the messageBusAddress
190 public SdcReceptionHandlerConfigurationParameterBuilder setMessageBusAddress(final List<String> messageBusAddress) {
191 this.messageBusAddress = messageBusAddress;
196 * Set artifactTypes to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
198 * @param artifactTypes the artifactTypes
200 public SdcReceptionHandlerConfigurationParameterBuilder setArtifactTypes(final List<String> artifactTypes) {
201 this.artifactTypes = artifactTypes;
206 * Set retryDelay to this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
208 * @param retryDelay the retryDelay
210 public SdcReceptionHandlerConfigurationParameterBuilder setRetryDelay(final int retryDelay) {
211 this.retryDelay = retryDelay;
216 * Returns the active server TlsAuth of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
218 * @return the activeserverTlsAuth
220 public boolean isActiveserverTlsAuth() {
221 return activeserverTlsAuth;
225 * Returns the isFilterinEmptyResources flag of this {@link SdcReceptionHandlerConfigurationParameterBuilder}
228 * @return the isFilterinEmptyResources
230 public boolean isFilterinEmptyResources() {
231 return filterinEmptyResources;
235 * Returns the isUseHttpsWithDmaap flag of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
237 * @return the isUseHttpsWithDmaap
239 public Boolean getIsUseHttpsWithDmaap() {
240 return useHttpsWithDmaap;
244 * Returns the isUseHttpsWithSDC flag of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
246 * @return the isUseHttpsWithSDC
248 public Boolean getIsUseHttpsWithSDC() {
249 return useHttpsWithSDC;
253 * Returns the polling interval of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
255 * @return the pollingInterval
257 public int getPollingInterval() {
258 return pollingInterval;
262 * Returns the polling timeout of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
264 * @return the pollingTimeout
266 public int getPollingTimeout() {
267 return pollingTimeout;
271 * Returns the asdc address of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
273 * @return the asdcAddress
275 public String getAsdcAddress() {
280 * Returns the user of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
284 public String getUser() {
289 * Returns the password of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
291 * @return the password
293 public String getPassword() {
298 * Returns the consumer id of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
300 * @return the consumerId
302 public String getConsumerId() {
307 * Returns the consumer group of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
309 * @return the consumerGroup
311 public String getConsumerGroup() {
312 return consumerGroup;
316 * Returns the environment name of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
318 * @return the environmentName
320 public String getEnvironmentName() {
321 return environmentName;
325 * Returns the keystore path of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
327 * @return the keystorePath
329 public String getKeystorePath() {
334 * Returns the keystore password of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
336 * @return the keystorePassword
338 public String getKeystorePassword() {
339 return keystorePassword;
343 * Returns the message bus address of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
345 * @return the messageBusAddress
347 public List<String> getMessageBusAddress() {
348 return messageBusAddress;
352 * Returns the artifact types of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
354 * @return the artifactTypes
356 public List<String> getArtifactTypes() {
357 return artifactTypes;
361 * Returns the retryDelay of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
363 * @return the retryDelay
365 public int getRetryDelay() {
369 * Returns the https proxy port of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
371 * @return the httpsproxyPort
373 public int getHttpsProxyPort() {
374 return httpsproxyPort;
377 * Returns the https proxy host of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
379 * @return the httpsproxyHost
381 public String getHttpsProxyHost() {
382 return httpsproxyHost;
385 * Returns the http proxy port of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
387 * @return the httpproxyPort
389 public int getHttpProxyPort() {
390 return httpproxyPort;
393 * Returns the http proxy host of this {@link SdcReceptionHandlerConfigurationParameterBuilder} instance.
395 * @return the httpsproxyHost
397 public String getHttpProxyHost() {
398 return httpproxyHost;