Package net.hydromatic.morel.ast
Class Ast.From
- java.lang.Object
-
- net.hydromatic.morel.ast.AstNode
-
- net.hydromatic.morel.ast.Ast.Exp
-
- net.hydromatic.morel.ast.Ast.From
-
-
Field Summary
Fields Modifier and Type Field Description @Nullable Ast.ExpimplicitYieldExpcom.google.common.collect.ImmutableList<Ast.FromStep>steps
-
Constructor Summary
Constructors Constructor Description From(Pos pos, com.google.common.collect.ImmutableList<Ast.FromStep> steps, @Nullable Ast.Exp implicitYieldExp)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Ast.Expaccept(Shuttle shuttle)Accepts a shuttle, calling theShuttle.visit(net.hydromatic.morel.ast.Ast.Literal)method appropriate to the type of this node, and returning the result.voidaccept(Visitor visitor)Accepts a visitor, calling theShuttle.visit(net.hydromatic.morel.ast.Ast.Literal)method appropriate to the type of this node, and returning the result.Ast.Fromcopy(List<Ast.FromStep> steps, @Nullable Ast.Exp implicitYieldExp)Creates a copy of thisFromwith given contents, orthisif the contents are the same.(package private) static @Nullable Ast.ExpimplicitYieldExp(Pos pos, List<Ast.FromStep> steps)booleanisCompute()Returns whether thisfromexpression ends with acomputestep.(package private) AstWriterunparse(AstWriter w, int left, int right)-
Methods inherited from class net.hydromatic.morel.ast.Ast.Exp
args, forEachArg
-
-
-
-
Field Detail
-
steps
public final com.google.common.collect.ImmutableList<Ast.FromStep> steps
-
implicitYieldExp
public final @Nullable Ast.Exp implicitYieldExp
-
-
Constructor Detail
-
From
From(Pos pos, com.google.common.collect.ImmutableList<Ast.FromStep> steps, @Nullable Ast.Exp implicitYieldExp)
-
-
Method Detail
-
implicitYieldExp
static @Nullable Ast.Exp implicitYieldExp(Pos pos, List<Ast.FromStep> steps)
-
accept
public Ast.Exp accept(Shuttle shuttle)
Description copied from class:AstNodeAccepts a shuttle, calling theShuttle.visit(net.hydromatic.morel.ast.Ast.Literal)method appropriate to the type of this node, and returning the result.
-
accept
public void accept(Visitor visitor)
Description copied from class:AstNodeAccepts a visitor, calling theShuttle.visit(net.hydromatic.morel.ast.Ast.Literal)method appropriate to the type of this node, and returning the result.
-
copy
public Ast.From copy(List<Ast.FromStep> steps, @Nullable Ast.Exp implicitYieldExp)
Creates a copy of thisFromwith given contents, orthisif the contents are the same.
-
isCompute
public boolean isCompute()
Returns whether thisfromexpression ends with acomputestep. If so, it is a monoid comprehension, not a monad comprehension, and its type is a scalar value (or record), not a list.
-
-