Classes
Members
(readonly) size :number
The size of the Set, which represents the number of entries currently in the Map.
Type:
- number
- Source:
Methods
add(_value) → {module:barejs/polyfill.Set}
Adds a value to a Set object.
Parameters:
Name | Type | Description |
---|---|---|
_value |
The value to add. |
- Source:
Returns:
The Set (for chaining)
clear()
Clear the Set.
- Source:
delete(_value) → {boolean}
Remove a value from the Set
Parameters:
Name | Type | Description |
---|---|---|
_value |
object | The value to remove. |
- Source:
Returns:
True if the value was deleted, false otherwise.
- Type
- boolean
entries() → {module:barejs/polyfill.Set~SetIterator}
Get an entry iterator
- Source:
Returns:
A entry iterator
forEach(_callback, _thisArgopt)
Iterate the Set
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
_callback |
function | The callback function. |
|
_thisArg |
<optional> |
Optional: context to call the callback in. |
- Source:
has(_value) → {boolean}
Check if the Set has a specified value.
Parameters:
Name | Type | Description |
---|---|---|
_value |
object | The value to check for. |
- Source:
Returns:
True if there is an entry for the value, false otherwise
- Type
- boolean
keys() → {module:barejs/polyfill.Set~SetIterator}
Get a key iterator
- Source:
Returns:
A key iterator
values() → {module:barejs/polyfill.Set~SetIterator}
Get a value iterator
- Source:
Returns:
A value iterator