private Object getFromData(StateEvent stateEvent, int[] fromPosition) {
        return stateEvent.getAttribute(fromPosition);
//        StreamEvent streamEvent = stateEvent.getStreamEvent(fromPosition[0]);
//        if (streamEvent == null) {
//            return null;
//        }
//        if (fromPosition[1] > 0) {
//            for (int i = 0, size = fromPosition[1]; i < size; i++) {
//                streamEvent = streamEvent.getNext();
//            }
//        }
//        switch (fromPosition[2]) {
//            case 0:
//                return streamEvent.getBeforeWindowData()[fromPosition[3]];
//            case 1:
//                return streamEvent.getOnAfterWindowData()[fromPosition[3]];
//            case 2:
//                return streamEvent.getEventTime()[fromPosition[3]];
//            default:
//                //will not happen
//                throw new IllegalStateException("3rd element in from position cannot be :" + fromPosition[2]);
//        }
    }
The populater class that populates StateEvents
modules/siddhi-core/src/main/java/io/siddhi/core/event/state/populater/SelectiveStateEventPopulator.java