Changes for checkstyle 8.32
[policy/apex-pdp.git] / plugins / plugins-event / plugins-event-carrier / plugins-event-carrier-restclient / src / main / java / org / onap / policy / apex / plugins / event / carrier / restclient / RestClientCarrierTechnologyParameters.java
1 /*-
2  * ============LICENSE_START=======================================================
3  *  Copyright (C) 2016-2018 Ericsson. All rights reserved.
4  *  Modifications Copyright (C) 2019-2020 Nordix Foundation.
5  * ================================================================================
6  * Licensed under the Apache License, Version 2.0 (the "License");
7  * you may not use this file except in compliance with the License.
8  * You may obtain a copy of the License at
9  *
10  *      http://www.apache.org/licenses/LICENSE-2.0
11  *
12  * Unless required by applicable law or agreed to in writing, software
13  * distributed under the License is distributed on an "AS IS" BASIS,
14  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15  * See the License for the specific language governing permissions and
16  * limitations under the License.
17  *
18  * SPDX-License-Identifier: Apache-2.0
19  * ============LICENSE_END=========================================================
20  */
21
22 package org.onap.policy.apex.plugins.event.carrier.restclient;
23
24 import lombok.Getter;
25 import lombok.Setter;
26 import org.onap.policy.apex.service.parameters.carriertechnology.RestPluginCarrierTechnologyParameters;
27
28 // @formatter:off
29 /**
30  * Apex parameters for REST as an event carrier technology with Apex as a REST client.
31  *
32  * <p>The parameters for this plugin are:
33  * <ol>
34  * <li>url: The URL that the Apex Rest client will connect to over REST for event reception or event sending. This
35  * parameter is mandatory.
36  * <li>httpMethod: The HTTP method to use when sending events over REST, legal values are POST (default) and PUT. When
37  * receiving events, the REST client plugin always uses the HTTP GET method.
38  * <li>httpHeaders, the HTTP headers to send on REST requests, optional parameter, defaults to none.
39  * <li>httpCodeFilter: a regular expression filter for returned HTTP codes, if the returned HTTP code passes this
40  * filter, then the request is assumed to have succeeded by the plugin, optional, defaults to allowing 2xx codes
41  * through, that is a regular expression of "[2][0-9][0-9]"
42  * </ol>
43  *
44  * @author Joss Armstrong (joss.armstrong@ericsson.com)
45  */
46 //@formatter:on
47 @Setter
48 @Getter
49 public class RestClientCarrierTechnologyParameters extends RestPluginCarrierTechnologyParameters {
50
51     /**
52      * Constructor to create a REST carrier technology parameters instance and register the instance with the parameter
53      * service.
54      */
55     public RestClientCarrierTechnologyParameters() {
56         super();
57
58         this.setLabel("RESTCLIENT");
59         this.setEventProducerPluginClass(ApexRestClientProducer.class.getName());
60         this.setEventConsumerPluginClass(ApexRestClientConsumer.class.getName());
61     }
62 }