term method

Query term(
  1. dynamic term, [
  2. Clause? options
])

Implementation

Query term(dynamic term, [Clause? options]) {
  if (term! is String && term! is List<dynamic>) {
    throw Exception(
        'The first paramter needs to be String or a list of Strings ');
  }
  if (term is List<dynamic>) {
    for (dynamic t in term) {
      this.term(t, options?.clone());
    }
    return this;
  }

  Clause clause = options ?? Clause();
  clause.term = term.toString();
  this.clause(clause);
  return this;
}