defines.dart 1.1 KB

1234567891011121314151617181920212223242526272829
  1. import 'dart:collection';
  2. import 'package:appflowy/plugins/database_view/grid/presentation/widgets/sort/sort_info.dart';
  3. import 'package:appflowy_backend/protobuf/flowy-database2/database_entities.pb.dart';
  4. import 'package:appflowy_backend/protobuf/flowy-error/errors.pb.dart';
  5. import '../grid/presentation/widgets/filter/filter_info.dart';
  6. import 'field/field_controller.dart';
  7. import 'row/row_cache.dart';
  8. import 'row/row_service.dart';
  9. typedef OnFieldsChanged = void Function(UnmodifiableListView<FieldInfo>);
  10. typedef OnFiltersChanged = void Function(List<FilterInfo>);
  11. typedef OnSortsChanged = void Function(List<SortInfo>);
  12. typedef OnDatabaseChanged = void Function(DatabasePB);
  13. typedef OnRowsCreated = void Function(List<RowId> ids);
  14. typedef OnRowsUpdated = void Function(
  15. List<RowId> ids,
  16. ChangedReason reason,
  17. );
  18. typedef OnRowsDeleted = void Function(List<RowId> ids);
  19. typedef OnNumOfRowsChanged = void Function(
  20. UnmodifiableListView<RowInfo> rows,
  21. UnmodifiableMapView<RowId, RowInfo> rowByRowId,
  22. ChangedReason reason,
  23. );
  24. typedef OnError = void Function(FlowyError);