text property

  1. @override
String get text
override

The text of the condition.

Implementation

@override
String get text {
  if (checkColumn && !_checkDateColumn(column)) {
    assert(
      checkColumn && !_checkDateColumn(column),
      'Only `createDate`, `modifiedDate`, `dateTaken`,'
      'and `dateExpires` are support.',
    );
    return '';
  }
  final sb = StringBuffer();
  sb.write(column);
  sb.write(' $operator ');
  bool isSecond = true;
  if (Platform.isAndroid) {
    isSecond = column != CustomColumns.android.dateTaken;
  }
  final sql = CustomColumns.utils.convertDateTimeToSql(
    value,
    isSeconds: isSecond,
  );
  sb.write(' $sql');
  return sb.toString();
}