Package com.odiago.flumebase.parser

Examples of com.odiago.flumebase.parser.Expr.eval()


    // Evaluate all our input expressions, left-to-right, and emit
    // their results into the output record.
    for (AliasedExpr aliasedExpr : mExprs) {
      Expr expr = aliasedExpr.getExpr();
      Object result = nativeToAvro(expr.eval(e), expr.getResolvedType());
      String fieldName = aliasedExpr.getAvroLabel();
      record.put(fieldName, result);
    }

    // Now add to our output record, any fields that we can pull in directly from
View Full Code Here


    mPropagateFields = aggregateNode.getPropagateFields();

    Expr windowExpr = aggregateNode.getWindowExpr();
    assert windowExpr.isConstant();
    try {
      mWindowSpec = (WindowSpec) windowExpr.eval(new EmptyEventWrapper());
      assert mWindowSpec.getRangeSpec().isConstant();
      mTimeSpan = (TimeSpan) mWindowSpec.getRangeSpec().eval(new EmptyEventWrapper());
    } catch (IOException ioe) {
      // The only way this can be thrown is if the window expr isn't actually constant.
      // This should not happen due to the assert above..
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.