UNPKG

1.48 kBTypeScriptView Raw
1import { Injector } from '../injector';
2/**
3 * @license
4 * Copyright Google Inc. All Rights Reserved.
5 *
6 * Use of this source code is governed by an MIT-style license that can be
7 * found in the LICENSE file at https://angular.io/license
8 */
9export interface BrowserNodeGlobal {
10 Object: typeof Object;
11 Array: typeof Array;
12 Map: typeof Map;
13 Set: typeof Set;
14 Date: DateConstructor;
15 RegExp: RegExpConstructor;
16 JSON: typeof JSON;
17 Math: any;
18 assert(condition: any): void;
19 Reflect: any;
20 getAngularTestability: Function;
21 getAllAngularTestabilities: Function;
22 getAllAngularRootElements: Function;
23 frameworkStabilizers: Array<Function>;
24 setTimeout: Function;
25 clearTimeout: Function;
26 setInterval: Function;
27 clearInterval: Function;
28 encodeURI: Function;
29}
30declare const _global: BrowserNodeGlobal;
31export { _global as global };
32export declare function isPresent<T>(obj: T): obj is NonNullable<T>;
33export declare function stringify(token: any): string;
34export declare abstract class DebugContext {
35 abstract get nodeIndex(): number | null;
36 abstract get injector(): Injector;
37 abstract get component(): any;
38 abstract get providerTokens(): any[];
39 abstract get references(): {
40 [key: string]: any;
41 };
42 abstract get context(): any;
43 abstract get componentRenderElement(): any;
44 abstract get renderNode(): any;
45 abstract logError(console: Console, ...values: any[]): void;
46}