public class Expressions
extends java.lang.Object
expressions
.Modifier and Type | Method and Description |
---|---|
static False |
alwaysFalse() |
static True |
alwaysTrue() |
static Expression |
and(Expression left,
Expression right) |
static Expression |
and(Expression left,
Expression right,
Expression... expressions) |
static <T> UnboundTerm<T> |
bucket(java.lang.String name,
int numBuckets) |
static <T> UnboundTerm<T> |
day(java.lang.String name) |
static <T> UnboundPredicate<T> |
equal(java.lang.String name,
T value) |
static <T> UnboundPredicate<T> |
equal(UnboundTerm<T> expr,
T value) |
static <T> UnboundPredicate<T> |
greaterThan(java.lang.String name,
T value) |
static <T> UnboundPredicate<T> |
greaterThan(UnboundTerm<T> expr,
T value) |
static <T> UnboundPredicate<T> |
greaterThanOrEqual(java.lang.String name,
T value) |
static <T> UnboundPredicate<T> |
greaterThanOrEqual(UnboundTerm<T> expr,
T value) |
static <T> UnboundTerm<T> |
hour(java.lang.String name) |
static <T> UnboundPredicate<T> |
in(java.lang.String name,
java.lang.Iterable<T> values) |
static <T> UnboundPredicate<T> |
in(java.lang.String name,
T... values) |
static <T> UnboundPredicate<T> |
in(UnboundTerm<T> expr,
java.lang.Iterable<T> values) |
static <T> UnboundPredicate<T> |
in(UnboundTerm<T> expr,
T... values) |
static <T> UnboundPredicate<T> |
isNaN(java.lang.String name) |
static <T> UnboundPredicate<T> |
isNaN(UnboundTerm<T> expr) |
static <T> UnboundPredicate<T> |
isNull(java.lang.String name) |
static <T> UnboundPredicate<T> |
isNull(UnboundTerm<T> expr) |
static <T> UnboundPredicate<T> |
lessThan(java.lang.String name,
T value) |
static <T> UnboundPredicate<T> |
lessThan(UnboundTerm<T> expr,
T value) |
static <T> UnboundPredicate<T> |
lessThanOrEqual(java.lang.String name,
T value) |
static <T> UnboundPredicate<T> |
lessThanOrEqual(UnboundTerm<T> expr,
T value) |
static <T> UnboundTerm<T> |
month(java.lang.String name) |
static Expression |
not(Expression child) |
static <T> UnboundPredicate<T> |
notEqual(java.lang.String name,
T value) |
static <T> UnboundPredicate<T> |
notEqual(UnboundTerm<T> expr,
T value) |
static <T> UnboundPredicate<T> |
notIn(java.lang.String name,
java.lang.Iterable<T> values) |
static <T> UnboundPredicate<T> |
notIn(java.lang.String name,
T... values) |
static <T> UnboundPredicate<T> |
notIn(UnboundTerm<T> expr,
java.lang.Iterable<T> values) |
static <T> UnboundPredicate<T> |
notIn(UnboundTerm<T> expr,
T... values) |
static <T> UnboundPredicate<T> |
notNaN(java.lang.String name) |
static <T> UnboundPredicate<T> |
notNaN(UnboundTerm<T> expr) |
static <T> UnboundPredicate<T> |
notNull(java.lang.String name) |
static <T> UnboundPredicate<T> |
notNull(UnboundTerm<T> expr) |
static Expression |
or(Expression left,
Expression right) |
static <T> UnboundPredicate<T> |
predicate(Expression.Operation op,
java.lang.String name) |
static <T> UnboundPredicate<T> |
predicate(Expression.Operation op,
java.lang.String name,
java.lang.Iterable<T> values) |
static <T> UnboundPredicate<T> |
predicate(Expression.Operation op,
java.lang.String name,
Literal<T> lit) |
static <T> UnboundPredicate<T> |
predicate(Expression.Operation op,
java.lang.String name,
T value) |
static <T> NamedReference<T> |
ref(java.lang.String name)
Constructs a reference for a given column.
|
static Expression |
rewriteNot(Expression expr) |
static UnboundPredicate<java.lang.String> |
startsWith(java.lang.String name,
java.lang.String value) |
static UnboundPredicate<java.lang.String> |
startsWith(UnboundTerm<java.lang.String> expr,
java.lang.String value) |
static <T> UnboundTerm<T> |
transform(java.lang.String name,
Transform<?,T> transform)
Constructs a transform expression for a given column.
|
static <T> UnboundTerm<T> |
truncate(java.lang.String name,
int width) |
static <T> UnboundTerm<T> |
year(java.lang.String name) |
public static Expression and(Expression left, Expression right)
public static Expression and(Expression left, Expression right, Expression... expressions)
public static Expression or(Expression left, Expression right)
public static Expression not(Expression child)
public static <T> UnboundTerm<T> bucket(java.lang.String name, int numBuckets)
public static <T> UnboundTerm<T> year(java.lang.String name)
public static <T> UnboundTerm<T> month(java.lang.String name)
public static <T> UnboundTerm<T> day(java.lang.String name)
public static <T> UnboundTerm<T> hour(java.lang.String name)
public static <T> UnboundTerm<T> truncate(java.lang.String name, int width)
public static <T> UnboundPredicate<T> isNull(java.lang.String name)
public static <T> UnboundPredicate<T> isNull(UnboundTerm<T> expr)
public static <T> UnboundPredicate<T> notNull(java.lang.String name)
public static <T> UnboundPredicate<T> notNull(UnboundTerm<T> expr)
public static <T> UnboundPredicate<T> isNaN(java.lang.String name)
public static <T> UnboundPredicate<T> isNaN(UnboundTerm<T> expr)
public static <T> UnboundPredicate<T> notNaN(java.lang.String name)
public static <T> UnboundPredicate<T> notNaN(UnboundTerm<T> expr)
public static <T> UnboundPredicate<T> lessThan(java.lang.String name, T value)
public static <T> UnboundPredicate<T> lessThan(UnboundTerm<T> expr, T value)
public static <T> UnboundPredicate<T> lessThanOrEqual(java.lang.String name, T value)
public static <T> UnboundPredicate<T> lessThanOrEqual(UnboundTerm<T> expr, T value)
public static <T> UnboundPredicate<T> greaterThan(java.lang.String name, T value)
public static <T> UnboundPredicate<T> greaterThan(UnboundTerm<T> expr, T value)
public static <T> UnboundPredicate<T> greaterThanOrEqual(java.lang.String name, T value)
public static <T> UnboundPredicate<T> greaterThanOrEqual(UnboundTerm<T> expr, T value)
public static <T> UnboundPredicate<T> equal(java.lang.String name, T value)
public static <T> UnboundPredicate<T> equal(UnboundTerm<T> expr, T value)
public static <T> UnboundPredicate<T> notEqual(java.lang.String name, T value)
public static <T> UnboundPredicate<T> notEqual(UnboundTerm<T> expr, T value)
public static UnboundPredicate<java.lang.String> startsWith(java.lang.String name, java.lang.String value)
public static UnboundPredicate<java.lang.String> startsWith(UnboundTerm<java.lang.String> expr, java.lang.String value)
public static <T> UnboundPredicate<T> in(java.lang.String name, T... values)
public static <T> UnboundPredicate<T> in(UnboundTerm<T> expr, T... values)
public static <T> UnboundPredicate<T> in(java.lang.String name, java.lang.Iterable<T> values)
public static <T> UnboundPredicate<T> in(UnboundTerm<T> expr, java.lang.Iterable<T> values)
public static <T> UnboundPredicate<T> notIn(java.lang.String name, T... values)
public static <T> UnboundPredicate<T> notIn(UnboundTerm<T> expr, T... values)
public static <T> UnboundPredicate<T> notIn(java.lang.String name, java.lang.Iterable<T> values)
public static <T> UnboundPredicate<T> notIn(UnboundTerm<T> expr, java.lang.Iterable<T> values)
public static <T> UnboundPredicate<T> predicate(Expression.Operation op, java.lang.String name, T value)
public static <T> UnboundPredicate<T> predicate(Expression.Operation op, java.lang.String name, Literal<T> lit)
public static <T> UnboundPredicate<T> predicate(Expression.Operation op, java.lang.String name, java.lang.Iterable<T> values)
public static <T> UnboundPredicate<T> predicate(Expression.Operation op, java.lang.String name)
public static True alwaysTrue()
public static False alwaysFalse()
public static Expression rewriteNot(Expression expr)
public static <T> NamedReference<T> ref(java.lang.String name)
The following are equivalent: equals("a", 5) and equals(ref("a"), 5).
T
- the Java type of this referencename
- a column namepublic static <T> UnboundTerm<T> transform(java.lang.String name, Transform<?,T> transform)
T
- the Java type of this termname
- a column nametransform
- a transform function