collection-viewer.d.ts 806 B

123456789101112131415161718192021222324
  1. /**
  2. * @license
  3. * Copyright Google LLC All Rights Reserved.
  4. *
  5. * Use of this source code is governed by an MIT-style license that can be
  6. * found in the LICENSE file at https://angular.io/license
  7. */
  8. import { Observable } from 'rxjs';
  9. /** Represents a range of numbers with a specified start and end. */
  10. export declare type ListRange = {
  11. start: number;
  12. end: number;
  13. };
  14. /**
  15. * Interface for any component that provides a view of some data collection and wants to provide
  16. * information regarding the view and any changes made.
  17. */
  18. export interface CollectionViewer {
  19. /**
  20. * A stream that emits whenever the `CollectionViewer` starts looking at a new portion of the
  21. * data. The `start` index is inclusive, while the `end` is exclusive.
  22. */
  23. viewChange: Observable<ListRange>;
  24. }