| RankedSetTReplace Method (T, Boolean) |
Replace an item or optionally add it if missing.
Namespace:
Kaos.Collections
Assembly:
KaosCollections (in KaosCollections.dll) Version: 4.2.0.0
Syntax public bool Replace(
T item,
bool addIfMissing
)
Parameters
- item
- Type: T
The replacement or new item. - addIfMissing
- Type: SystemBoolean
true to add item if not already present.
Return Value
Type:
Booleantrue if item is replaced; otherwise
false.
Remarks
This operation is an optimized alternative to performing the implicit operations separately.
See Also