summaryrefslogtreecommitdiffstats
path: root/plugins/plugins-event
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/plugins-event')
-rw-r--r--plugins/plugins-event/plugins-event-carrier/plugins-event-carrier-restclient/src/test/java/org/onap/policy/apex/plugins/event/carrier/restclient/SupportApexEventReceiver.java20
-rw-r--r--plugins/plugins-event/plugins-event-carrier/plugins-event-carrier-restserver/src/test/java/org/onap/policy/apex/plugins/event/carrier/restserver/SupportApexEventReceiver.java20
-rw-r--r--plugins/plugins-event/plugins-event-protocol/plugins-event-protocol-xml/src/test/java/org/onap/policy/apex/plugins/event/protocol/xml/XmlEventGenerator.java12
3 files changed, 9 insertions, 43 deletions
diff --git a/plugins/plugins-event/plugins-event-carrier/plugins-event-carrier-restclient/src/test/java/org/onap/policy/apex/plugins/event/carrier/restclient/SupportApexEventReceiver.java b/plugins/plugins-event/plugins-event-carrier/plugins-event-carrier-restclient/src/test/java/org/onap/policy/apex/plugins/event/carrier/restclient/SupportApexEventReceiver.java
index f2201379d..49135f5d4 100644
--- a/plugins/plugins-event/plugins-event-carrier/plugins-event-carrier-restclient/src/test/java/org/onap/policy/apex/plugins/event/carrier/restclient/SupportApexEventReceiver.java
+++ b/plugins/plugins-event/plugins-event-carrier/plugins-event-carrier-restclient/src/test/java/org/onap/policy/apex/plugins/event/carrier/restclient/SupportApexEventReceiver.java
@@ -2,6 +2,7 @@
* ============LICENSE_START=======================================================
* Copyright (C) 2018 Ericsson. All rights reserved.
* Modifications Copyright (C) 2019 Nordix Foundation.
+ * Modifications Copyright (C) 2021 AT&T Intellectual Property. All rights reserved.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -22,6 +23,7 @@
package org.onap.policy.apex.plugins.event.carrier.restclient;
import java.util.Properties;
+import lombok.Getter;
import org.onap.policy.apex.service.engine.event.ApexEventException;
import org.onap.policy.apex.service.engine.event.ApexEventReceiver;
@@ -29,6 +31,7 @@ import org.onap.policy.apex.service.engine.event.ApexEventReceiver;
* Support Apex event reveiver for unit test.
*
*/
+@Getter
public class SupportApexEventReceiver implements ApexEventReceiver {
private long lastExecutionId;
private Object lastEvent;
@@ -53,21 +56,4 @@ public class SupportApexEventReceiver implements ApexEventReceiver {
this.lastEvent = event;
this.eventCount++;
}
-
- public long getLastExecutionId() {
- return lastExecutionId;
- }
-
- public Object getLastEvent() {
- return lastEvent;
- }
-
- /**
- * Get the number of events received.
- *
- * @return the number of events received
- */
- public int getEventCount() {
- return eventCount;
- }
}
diff --git a/plugins/plugins-event/plugins-event-carrier/plugins-event-carrier-restserver/src/test/java/org/onap/policy/apex/plugins/event/carrier/restserver/SupportApexEventReceiver.java b/plugins/plugins-event/plugins-event-carrier/plugins-event-carrier-restserver/src/test/java/org/onap/policy/apex/plugins/event/carrier/restserver/SupportApexEventReceiver.java
index cd60c220d..773ecafb2 100644
--- a/plugins/plugins-event/plugins-event-carrier/plugins-event-carrier-restserver/src/test/java/org/onap/policy/apex/plugins/event/carrier/restserver/SupportApexEventReceiver.java
+++ b/plugins/plugins-event/plugins-event-carrier/plugins-event-carrier-restserver/src/test/java/org/onap/policy/apex/plugins/event/carrier/restserver/SupportApexEventReceiver.java
@@ -1,6 +1,7 @@
/*-
* ============LICENSE_START=======================================================
* Copyright (C) 2018 Ericsson. All rights reserved.
+ * Modifications Copyright (C) 2021 AT&T Intellectual Property. All rights reserved.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -21,6 +22,7 @@
package org.onap.policy.apex.plugins.event.carrier.restserver;
import java.util.Properties;
+import lombok.Getter;
import org.onap.policy.apex.service.engine.event.ApexEventException;
import org.onap.policy.apex.service.engine.event.ApexEventReceiver;
@@ -28,6 +30,7 @@ import org.onap.policy.apex.service.engine.event.ApexEventReceiver;
* Support Apex event reveiver for unit test.
*
*/
+@Getter
public class SupportApexEventReceiver implements ApexEventReceiver {
private long lastExecutionId;
private Object lastEvent;
@@ -52,21 +55,4 @@ public class SupportApexEventReceiver implements ApexEventReceiver {
this.lastEvent = event;
this.eventCount++;
}
-
- public long getLastExecutionId() {
- return lastExecutionId;
- }
-
- public Object getLastEvent() {
- return lastEvent;
- }
-
- /**
- * Get the number of events received.
- *
- * @return the number of events received
- */
- public int getEventCount() {
- return eventCount;
- }
}
diff --git a/plugins/plugins-event/plugins-event-protocol/plugins-event-protocol-xml/src/test/java/org/onap/policy/apex/plugins/event/protocol/xml/XmlEventGenerator.java b/plugins/plugins-event/plugins-event-protocol/plugins-event-protocol-xml/src/test/java/org/onap/policy/apex/plugins/event/protocol/xml/XmlEventGenerator.java
index f85d9119e..9c8696c6c 100644
--- a/plugins/plugins-event/plugins-event-protocol/plugins-event-protocol-xml/src/test/java/org/onap/policy/apex/plugins/event/protocol/xml/XmlEventGenerator.java
+++ b/plugins/plugins-event/plugins-event-protocol/plugins-event-protocol-xml/src/test/java/org/onap/policy/apex/plugins/event/protocol/xml/XmlEventGenerator.java
@@ -1,6 +1,7 @@
/*-
* ============LICENSE_START=======================================================
* Copyright (C) 2016-2018 Ericsson. All rights reserved.
+ * Modifications Copyright (C) 2021 AT&T Intellectual Property. All rights reserved.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -21,11 +22,13 @@
package org.onap.policy.apex.plugins.event.protocol.xml;
import java.util.Random;
+import lombok.Getter;
/**
* The Class XmlEventGenerator.
*/
public class XmlEventGenerator {
+ @Getter
private static int nextEventNo = 0;
/**
@@ -113,13 +116,4 @@ public class XmlEventGenerator {
System.out.println(xmlEvents(eventCount));
}
-
- /**
- * Gets the next event no.
- *
- * @return the next event no
- */
- public static int getNextEventNo() {
- return nextEventNo;
- }
}