new Set(names)
Create a set containing some unique names.
Parameters:
| Name | Type | Argument | Description |
|---|---|---|---|
names |
Array.<string> |
<repeatable> |
to be in the set, implied to be unique. |
Methods
-
import(other)
-
Import another set.
Parameters:
Name Type Description othermodule:EBNF~Set to import.
Returns:
this set, changed.
- Type
- module:EBNF~Set
-
includes(other)
-
Check if this set includes another set.
Parameters:
Name Type Description othermodule:EBNF~Set the other set.
Returns:
true if the other set is a subset of this set.
- Type
- boolean
-
match(tuple)
-
Check if next input matches.
Parameters:
Name Type Argument Description tuplemodule:Base~Tuple <nullable>
next available input symbol.
Returns:
true if matched, false otherwise.
- Type
- boolean
-
overlap(other)
-
Check if two sets overlap.
Parameters:
Name Type Description othermodule:EBNF~Set the other set.
Returns:
the overlap, a new set, may be empty.
- Type
- module:EBNF~Set
-
toString()
-
Displays the elements.