# Sandbox.SelectionSystem

An ordered collection of unique objects with add/remove callbacks.
Maintains insertion order and provides change notifications.

- Kind: class
- Namespace: `Sandbox`
- Assembly: `Sandbox.System`

## Constructors

- [`SelectionSystem`](/api/Sandbox.SelectionSystem/.ctor)

## Properties

- [`Count`](/api/Sandbox.SelectionSystem/Count): Gets the number of selected objects.
- [`OnItemAdded`](/api/Sandbox.SelectionSystem/OnItemAdded): Invoked when an item is added to the selection.
- [`OnItemRemoved`](/api/Sandbox.SelectionSystem/OnItemRemoved): Invoked when an item is removed from the selection.

## Methods

- [`Add`](/api/Sandbox.SelectionSystem/Add): Adds an object to the selection.
- [`Any`](/api/Sandbox.SelectionSystem/Any): Checks if the selection contains any objects.
- [`Clear`](/api/Sandbox.SelectionSystem/Clear): Removes all objects from the selection, invoking OnItemRemoved for each.
- [`ConstructTitle`](/api/Sandbox.SandboxToolExtensions/ConstructTitle): Create a feasible title from the current selection
- [`Contains`](/api/Sandbox.SelectionSystem/Contains): Checks if an object is in the selection.
- [`GetEnumerator`](/api/Sandbox.SelectionSystem/GetEnumerator): Returns an enumerator that iterates through the selected objects in order.
- [`Remove`](/api/Sandbox.SelectionSystem/Remove): Removes an object from the selection.
- [`Set`](/api/Sandbox.SelectionSystem/Set): Clears the selection and sets it to a single object.
