@Override
        public boolean canDestroy() {
            return sessionMap.isEmpty() && expiredEventChunk.getFirst() == null
                    && sessionContainer.getCurrentSession().getFirst() == null
                    && sessionContainer.getPreviousSession().getFirst() == null;
        }
Collection used to manage session windows.

@param <E> sub types of ComplexEvent such as StreamEvent and StateEvent.
modules/siddhi-core/src/main/java/io/siddhi/core/query/processor/stream/window/SessionWindowProcessor.java