6c5d551838567111585e0e0d6149ab181b64102e
[policy/apex-pdp.git] /
1 /*-
2  * ============LICENSE_START=======================================================
3  *  Copyright (C) 2016-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.apex.service.engine.parameters.dummyclasses;
22
23 import org.onap.policy.apex.service.engine.event.ApexEventConsumer;
24 import org.onap.policy.apex.service.engine.event.ApexEventException;
25 import org.onap.policy.apex.service.engine.event.ApexEventReceiver;
26 import org.onap.policy.apex.service.engine.event.PeeredReference;
27 import org.onap.policy.apex.service.parameters.eventhandler.EventHandlerParameters;
28 import org.onap.policy.apex.service.parameters.eventhandler.EventHandlerPeeredMode;
29 import org.slf4j.ext.XLogger;
30 import org.slf4j.ext.XLoggerFactory;
31
32 public class SuperDooperEventSubscriber implements ApexEventConsumer {
33
34     private static final XLogger LOGGER = XLoggerFactory.getXLogger(SuperDooperEventSubscriber.class);
35
36     private String name;
37
38     public SuperDooperEventSubscriber() {}
39
40     @Override
41     public void init(final String name, final EventHandlerParameters consumerParameters,
42             final ApexEventReceiver apexEventReceiver) throws ApexEventException {
43         this.name = name;
44         LOGGER.info("Initialising Apex Consumer: " + this.getClass().getCanonicalName() + ":" + this.name);
45     }
46
47     @Override
48     public String getName() {
49         return name;
50     }
51
52     /**
53      * {@inheritDoc}.
54      */
55     @Override
56     public PeeredReference getPeeredReference(final EventHandlerPeeredMode peeredMode) {
57         return null;
58     }
59
60     /**
61      * {@inheritDoc}.
62      */
63     @Override
64     public void setPeeredReference(final EventHandlerPeeredMode peeredMode, final PeeredReference peeredReference) {}
65
66     @Override
67     public void start() {
68         // TODO Auto-generated method stub
69
70     }
71
72     @Override
73     public void stop() {}
74
75 }