Search in sources :

Example 1 with CountingOutputStreamEventHandler

use of org.n52.iceland.statistics.impl.handlers.CountingOutputStreamEventHandler in project arctic-sea by 52North.

the class EventHandlerFinderTest method findDirectDefaultServiceEvent.

@Test
public void findDirectDefaultServiceEvent() {
    Map<String, StatisticsServiceEventHandler<?>> handlers = new HashMap<>();
    CountingOutputStreamEventHandler handler = new CountingOutputStreamEventHandler();
    CountingOutputStreamEvent request = new CountingOutputStreamEvent();
    handlers.put(request.getClass().getSimpleName(), handler);
    Assert.assertNotNull(EventHandlerFinder.findHandler(request, handlers));
}
Also used : HashMap(java.util.HashMap) CountingOutputStreamEvent(org.n52.iceland.event.events.CountingOutputStreamEvent) CountingOutputStreamEventHandler(org.n52.iceland.statistics.impl.handlers.CountingOutputStreamEventHandler) StatisticsServiceEventHandler(org.n52.iceland.statistics.api.interfaces.StatisticsServiceEventHandler) Test(org.junit.Test)

Aggregations

HashMap (java.util.HashMap)1 Test (org.junit.Test)1 CountingOutputStreamEvent (org.n52.iceland.event.events.CountingOutputStreamEvent)1 StatisticsServiceEventHandler (org.n52.iceland.statistics.api.interfaces.StatisticsServiceEventHandler)1 CountingOutputStreamEventHandler (org.n52.iceland.statistics.impl.handlers.CountingOutputStreamEventHandler)1