Show / Hide Table of Contents

Class Aggregand

Expression which is used to "group by" in an aggregation from one table to another.

Inheritance
Object
Expression
Expression<Aggregand, Aggregation>
Aggregand
Implements
IVisitable<IExpressionVisitor>
ICloneable<Aggregand, Aggregation, Expression>
ICloneable<Expression>
IDirectedAcyclicGraph<Expression>
Inherited Members
Expression<Aggregand, Aggregation>.Table
Expression<Aggregand, Aggregation>.Clone(Aggregation, IReadOnlyList<Expression>)
Expression<Aggregand, Aggregation>.Clone(IReadOnlyList<Expression>)
Expression.Table
Expression.ToString()
Expression.Clone(IReadOnlyList<Expression>)
Object.Equals(Object)
Object.Equals(Object, Object)
Object.GetHashCode()
Object.GetType()
Object.MemberwiseClone()
Object.ReferenceEquals(Object, Object)
Namespace: Mangrove.MetricSetSyntaxTree.ExpressionNodes
Assembly: MetricSetSyntaxTree.dll
Syntax
public class Aggregand : Expression<Aggregand, Aggregation>, IVisitable<IExpressionVisitor>, ICloneable<Aggregand, Aggregation, Expression>, ICloneable<Expression>, IDirectedAcyclicGraph<Expression>
Remarks

To motivate aggregands, consider the SQL statement:

WITH BASE_TABLE AS ( SELECT State, City, Population FROM DATA_SOURCE ), STATEWIDE_TABLE AS ( SELECT State, SUM(Population) AS Population FROM BASE_TABLE GROUP BY State )

In generating the state-wide table, the GROUP BY clause refers to the State column in BASE_TABLE. In Mangrove, an Aggregand provides this link.

Constructors

View Source

Aggregand(Aggregation, Expression)

Declaration
public Aggregand(Aggregation table, Expression source)
Parameters
Type Name Description
Aggregation table
Expression source

Properties

View Source

Parents

Declaration
[JsonIgnore]
public override IReadOnlyList<Expression> Parents { get; }
Property Value
Type Description
IReadOnlyList<Expression>
Overrides
Expression.Parents
View Source

Source

One of the columns you "group by" to get from the Source table to the "target" table.

Declaration
public Expression Source { get; }
Property Value
Type Description
Expression

Methods

View Source

Accept(IExpressionVisitor)

Declaration
public override void Accept(IExpressionVisitor visitor)
Parameters
Type Name Description
IExpressionVisitor visitor
Overrides
Expression.Accept(IExpressionVisitor)
View Source

Clone(Aggregation, IReadOnlyList<Expression>)

Declaration
public override Aggregand Clone(Aggregation table, IReadOnlyList<Expression> parents)
Parameters
Type Name Description
Aggregation table
IReadOnlyList<Expression> parents
Returns
Type Description
Aggregand
Overrides
Mangrove.MetricSetSyntaxTree.Expression<Mangrove.MetricSetSyntaxTree.ExpressionNodes.Aggregand, Mangrove.MetricSetSyntaxTree.TableNodes.Aggregation>.Clone(Mangrove.MetricSetSyntaxTree.TableNodes.Aggregation, System.Collections.Generic.IReadOnlyList<Mangrove.MetricSetSyntaxTree.Expression>)

Implements

IVisitable<TVisitor>
ICloneable<TSubnode, TIdentifier, TNode>
ICloneable<T>
IDirectedAcyclicGraph<T>

Extension Methods

ExpressionExtensions.WrapUniqueName(Expression, String)
ExpressionExtensions.WrapName(Expression, String)
ExpressionExtensions.Unwrap(Expression, Boolean)
ExpressionExtensions.UnwrapParentheses(Expression)
ExpressionExtensions.NeedsColumnReferenceWrap(Expression)
ExpressionExtensions.TopParentsOfType<TParent>(Expression)
ExpressionExtensions.References(Expression, ISet<Table>)
ExpressionExtensions.IsAggregation(Expression)
ExpressionExtensions.IsOperation(Expression)
ExpressionExtensions.IsConstant(Expression)
ExpressionExtensions.Type(Expression)
ExpressionExtensions.IsOfNullableType(Expression)
ExpressionExtensions.IsOfNonNullableType(Expression)
IDirectedAcyclicGraphExtensions.Ancestors(Expression, Boolean)
IDirectedAcyclicGraphExtensions.Closure(Expression)
ObjectExtensions.EventId(Object)
  • View Source
Back to top Generated by DocFX