@Override
    protected void process(ComplexEventChunk<StreamEvent> streamEventChunk, Processor nextProcessor,
                           StreamEventCloner streamEventCloner, WindowState state) {
        List<ComplexEventChunk> streamEventChunks = new LinkedList<>();
        synchronized (state) {
            ComplexEventChunk<StreamEvent> outputStreamEventChunk = new ComplexEventChunk<StreamEvent>();
            long currentTime = siddhiQueryContext.getSiddhiAppContext().getTimestampGenerator().currentTime();
            while (streamEventChunk.hasNext()) {
                StreamEvent streamEvent = streamEventChunk.next();
                streamEventChunk.remove();
                outputStreamEventChunk.add(streamEvent);
                if (outputExpectsExpiredEvents) {
                    StreamEvent expiredEvent = streamEventCloner.copyStreamEvent(streamEvent);
                    expiredEvent.setType(ComplexEvent.Type.EXPIRED);
                    expiredEvent.setTimestamp(currentTime);
                    outputStreamEventChunk.add(expiredEvent);
                }
                StreamEvent resetEvent = streamEventCloner.copyStreamEvent(streamEvent);
                resetEvent.setType(ComplexEvent.Type.RESET);
                resetEvent.setTimestamp(currentTime);
                outputStreamEventChunk.add(resetEvent);
                if (outputStreamEventChunk.getFirst() != null) {
                    streamEventChunks.add(outputStreamEventChunk);
                    outputStreamEventChunk = new ComplexEventChunk<>();
                }
            }
        }
        nextProcessor.process(streamEventChunks);
    }
Implementation of {@link WindowProcessor} which represent a Batch Window operating based on pre-defined length 0.
modules/siddhi-core/src/main/java/io/siddhi/core/query/processor/stream/window/EmptyWindowProcessor.java