class Collection
extends NodeBase
import { Collection } from "https://deno.land/x/windmill@v1.428.0/node_modules/yaml/browser/dist/nodes/Collection.js";
Methods
addIn(path, value)
Adds a value to the collection. For !!map
and !!omap
the value must
be a Pair instance or a { key, value }
object, which may not have a key
that already exists in the map.
clone(schema)
Create a copy of this collection.
deleteIn(path)
Removes a value from the collection.
getIn(path, keepScalar)
Returns item at key
, or undefined
if not found. By default unwraps
scalar values from their surrounding node; to disable set keepScalar
to
true
(collections are always returned intact).
hasAllNullValues(allowScalar)
hasIn(path)
Checks if the collection includes a value with the key key
.
setIn(path, value)
Sets a value in this collection. For !!set
, value
needs to be a
boolean to add/remove the item from the set.