@Override
    protected StateFactory<WindowState> init(ExpressionExecutor[] attributeExpressionExecutors,
                                             ConfigReader configReader,
                                             SiddhiQueryContext siddhiQueryContext) {
        mostFrequentCount = Integer.parseInt(String.valueOf(((ConstantExpressionExecutor)
                attributeExpressionExecutors[0]).getValue()));
        variableExpressionExecutors = new VariableExpressionExecutor[attributeExpressionExecutors.length - 1];
        for (int i = 1; i < attributeExpressionExecutors.length; i++) {
            variableExpressionExecutors[i - 1] = (VariableExpressionExecutor) attributeExpressionExecutors[i];
        }
        return () -> new WindowState();
    }
Implementation of {@link WindowProcessor} which represent a Window operating based on frequency of incoming events.
Implementation uses a counting algorithm based on Misra-Gries counting algorithm
modules/siddhi-core/src/main/java/io/siddhi/core/query/processor/stream/window/FrequentWindowProcessor.java