@Override
    public Object execute(ComplexEvent event) {
        if (expectEventObject) {
            return ((ComplexEvent) attributeExpressionExecutors[0].execute(event)).getTimestamp();
        } else {
            return event.getTimestamp();
        }
    }
Executor class for Siddhi cast function. Converts the given parameter according to the castTo parameter.
Incompatible arguments cause {@link ClassCastException} if further processed.
modules/siddhi-core/src/main/java/io/siddhi/core/executor/function/EventTimestampFunctionExecutor.java