SelectionHandler Class
A class that handles selection changes and helps to change internal the selection state.
Implements
Methods
Name | Description | |
---|---|---|
constructor(props: SelectionHandlerProps): SelectionHandler | Constructor. | |
addToSelection(keys: Keys, level: number0): void | Add to selection. | |
clearSelection(level: number0): void | Clear selection. | |
dispose(): void | Destructor. | |
getSelection(level?: number): Readonly<KeySet> | Get selection for the imodel managed by this handler. | |
getSelectionLevels(): number[] | Get selection levels for the imodel managed by this handler | |
onSelectionChanged(evt: SelectionChangeEventArgs, provider: ISelectionProvider): void Protected | Called when the selection changes. | |
removeFromSelection(keys: Keys, level: number0): void | Remove from selection. | |
replaceSelection(keys: Keys, level: number0): void | Change selection. | |
shouldHandle(evt: SelectionChangeEventArgs): boolean Protected | Called to check whether the event should be handled by this handler |
Properties
Name | Type | Description | |
---|---|---|---|
imodel | IModelConnection | iModel whose selection is being handled | |
manager Readonly | SelectionManager | Selection manager used by this handler to manage selection | |
name | string | Name that's used as SelectionChangeEventArgs.source when making selection changes |
|
onSelect | SelectionChangesListener | undefined | Callback function called when selection changes | |
rulesetId | string | undefined | Id of a ruleset selection changes will be associated with. |
Defined in
Last Updated: 14 November, 2024
Found something wrong, missing, or unclear on this page?Raise an issue in our repo.