UNPKG

921 BTypeScriptView Raw
1export type SettingsMap = {
2 [key: string]: any;
3};
4/**
5 * If a context value is an object with this key set to a truthy value, it won't be saved to cdk.context.json
6 */
7export declare const TRANSIENT_CONTEXT_KEY = "$dontSaveContext";
8/**
9 * A single bag of settings
10 */
11export declare class Settings {
12 private settings;
13 readonly readOnly: boolean;
14 static mergeAll(...settings: Settings[]): Settings;
15 constructor(settings?: SettingsMap, readOnly?: boolean);
16 load(fileName: string): Promise<this>;
17 save(fileName: string): Promise<this>;
18 get all(): any;
19 merge(other: Settings): Settings;
20 subSettings(keyPrefix: string[]): Settings;
21 makeReadOnly(): Settings;
22 clear(): void;
23 get empty(): boolean;
24 get(path: string[]): any;
25 set(path: string[], value: any): Settings;
26 unset(path: string[]): void;
27 private prohibitContextKey;
28 private warnAboutContextKey;
29}