source: trip-planner-front/node_modules/@angular/cdk/collections/unique-selection-dispatcher.d.ts.__ivy_ngcc_bak

Last change on this file was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago

initial commit

  • Property mode set to 100644
File size: 1.3 KB
Line 
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 */
8import { OnDestroy } from '@angular/core';
9export declare type UniqueSelectionDispatcherListener = (id: string, name: string) => void;
10/**
11 * Class to coordinate unique selection based on name.
12 * Intended to be consumed as an Angular service.
13 * This service is needed because native radio change events are only fired on the item currently
14 * being selected, and we still need to uncheck the previous selection.
15 *
16 * This service does not *store* any IDs and names because they may change at any time, so it is
17 * less error-prone if they are simply passed through when the events occur.
18 */
19export declare class UniqueSelectionDispatcher implements OnDestroy {
20 private _listeners;
21 /**
22 * Notify other items that selection for the given name has been set.
23 * @param id ID of the item.
24 * @param name Name of the item.
25 */
26 notify(id: string, name: string): void;
27 /**
28 * Listen for future changes to item selection.
29 * @return Function used to deregister listener
30 */
31 listen(listener: UniqueSelectionDispatcherListener): () => void;
32 ngOnDestroy(): void;
33}
Note: See TracBrowser for help on using the repository browser.