* @returns a boolean indicating whether all the elements in this Set are also in the argument.
(other: ReadonlySet<unknown>)
| 218 | * @returns a boolean indicating whether all the elements in this Set are also in the argument. |
| 219 | */ |
| 220 | public isSubsetOf(other: ReadonlySet<unknown>): boolean { |
| 221 | for (const item of this) { |
| 222 | if (!other.has(item)) { |
| 223 | return false; |
| 224 | } |
| 225 | } |
| 226 | return true; |
| 227 | } |
| 228 | |
| 229 | /** |
| 230 | * @returns a boolean indicating whether all the elements in the argument are also in this Set. |