labelNotEqualTo method

QueryBuilder<AnkiMapping, AnkiMapping, QAfterWhereClause> labelNotEqualTo(
  1. String label
)

Implementation

QueryBuilder<AnkiMapping, AnkiMapping, QAfterWhereClause> labelNotEqualTo(
    String label) {
  return QueryBuilder.apply(this, (query) {
    if (query.whereSort == Sort.asc) {
      return query
          .addWhereClause(IndexWhereClause.between(
            indexName: r'label',
            lower: [],
            upper: [label],
            includeUpper: false,
          ))
          .addWhereClause(IndexWhereClause.between(
            indexName: r'label',
            lower: [label],
            includeLower: false,
            upper: [],
          ));
    } else {
      return query
          .addWhereClause(IndexWhereClause.between(
            indexName: r'label',
            lower: [label],
            includeLower: false,
            upper: [],
          ))
          .addWhereClause(IndexWhereClause.between(
            indexName: r'label',
            lower: [],
            upper: [label],
            includeUpper: false,
          ));
    }
  });
}