From 383285ecd5292bf9a825e05904955b937de84cc9 Mon Sep 17 00:00:00 2001 From: Minteck Date: Sat, 4 Jun 2022 08:51:01 +0200 Subject: Initial commit --- node_modules/yaml/dist/nodes/YAMLMap.d.ts | 43 +++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) create mode 100644 node_modules/yaml/dist/nodes/YAMLMap.d.ts (limited to 'node_modules/yaml/dist/nodes/YAMLMap.d.ts') diff --git a/node_modules/yaml/dist/nodes/YAMLMap.d.ts b/node_modules/yaml/dist/nodes/YAMLMap.d.ts new file mode 100644 index 0000000..f13d7e5 --- /dev/null +++ b/node_modules/yaml/dist/nodes/YAMLMap.d.ts @@ -0,0 +1,43 @@ +import type { BlockMap, FlowCollection } from '../parse/cst.js'; +import type { Schema } from '../schema/Schema.js'; +import type { StringifyContext } from '../stringify/stringify.js'; +import { Collection } from './Collection.js'; +import { ParsedNode, Range } from './Node.js'; +import { Pair } from './Pair.js'; +import type { ToJSContext } from './toJS.js'; +export declare function findPair(items: Iterable>, key: unknown): Pair | undefined; +export declare namespace YAMLMap { + interface Parsed extends YAMLMap { + items: Pair[]; + range: Range; + srcToken?: BlockMap | FlowCollection; + } +} +export declare class YAMLMap extends Collection { + static get tagName(): 'tag:yaml.org,2002:map'; + items: Pair[]; + constructor(schema?: Schema); + /** + * Adds a value to the collection. + * + * @param overwrite - If not set `true`, using a key that is already in the + * collection will throw. Otherwise, overwrites the previous value. + */ + add(pair: Pair | { + key: K; + value: V; + }, overwrite?: boolean): void; + delete(key: K): boolean; + get(key: K, keepScalar?: boolean): unknown; + has(key: K): boolean; + set(key: K, value: V): void; + /** + * @param ctx - Conversion context, originally set in Document#toJS() + * @param {Class} Type - If set, forces the returned collection type + * @returns Instance of Type, Map, or Object + */ + toJSON(_?: unknown, ctx?: ToJSContext, Type?: { + new (): T; + }): any; + toString(ctx?: StringifyContext, onComment?: () => void, onChompKeep?: () => void): string; +} -- cgit