Module litebridge.db.spi.impl
Class Avg
java.lang.Object
org.litebridge.db.spi.impl.expression.AbstractExpression
org.litebridge.db.spi.impl.expression.AbstractAliasedExpression
org.litebridge.db.spi.impl.expression.function.FunctionExpression
org.litebridge.db.spi.impl.expression.function.aggregate.Avg
- All Implemented Interfaces:
AliasedExpression,DelegateExpression,SelectExpression
AVG(column) aggregate function.-
Field Summary
Fields inherited from class org.litebridge.db.spi.impl.expression.AbstractAliasedExpression
alias, tableAliasFields inherited from class org.litebridge.db.spi.impl.expression.AbstractExpression
labelGenerator -
Constructor Summary
ConstructorsConstructorDescriptionAvg(SelectExpression target, @Nullable String alias, LabelGenerator labelGenerator) Constructs a newAVGfunction expression. -
Method Summary
Methods inherited from class org.litebridge.db.spi.impl.expression.function.FunctionExpression
target, toSqlMethods inherited from class org.litebridge.db.spi.impl.expression.AbstractAliasedExpression
addAliasAs, alias, equals, hashCode, tableAlias, toStringMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.litebridge.db.spi.expression.SelectExpression
toSql
-
Constructor Details
-
Avg
Constructs a newAVGfunction expression.- Parameters:
target- The column expression to apply the function to.alias- The alias for the column expressionlabelGenerator- the label generator for rendering aliases/identifiers
-
-
Method Details
-
template
Description copied from class:FunctionExpressionGets the template for the SQL representation of the function.The template should contain a single "%s" placeholder for the column identifier.
- Specified by:
templatein classFunctionExpression- Returns:
- SQL representation template
-