lessThan method Null safety

QueryExpressionJunction<T, InstanceType> lessThan(
  1. T value
)

Adds a 'less than' expression to a query.

A query will only return objects where the selected property is less than value.

This method can be used on int, String, double and DateTime types. For DateTime properties, this method selects rows where the assigned property is 'earlier than' value. For String properties, rows are selected if the value is alphabetically 'before' value. Example:

  var query = new Query<Employee>()
    ..where((e) => e.salary).lessThan(60000);

Implementation

QueryExpressionJunction<T, InstanceType> lessThan(T value) {
  expression = ComparisonExpression(value, PredicateOperator.lessThan);

  return _createJunction();
}