1 | export interface BrowserNodeGlobal {
|
2 | Object: typeof Object;
|
3 | Array: typeof Array;
|
4 | Map: typeof Map;
|
5 | Set: typeof Set;
|
6 | Date: DateConstructor;
|
7 | RegExp: RegExpConstructor;
|
8 | JSON: typeof JSON;
|
9 | Math: any;
|
10 | assert(condition: any): void;
|
11 | Reflect: any;
|
12 | getAngularTestability: Function;
|
13 | getAllAngularTestabilities: Function;
|
14 | getAllAngularRootElements: Function;
|
15 | frameworkStabilizers: Array<Function>;
|
16 | setTimeout: Function;
|
17 | clearTimeout: Function;
|
18 | setInterval: Function;
|
19 | clearInterval: Function;
|
20 | encodeURI: Function;
|
21 | }
|
22 | export declare function scheduleMicroTask(fn: Function): void;
|
23 | export declare const IS_DART: boolean;
|
24 | declare var _global: BrowserNodeGlobal;
|
25 | export { _global as global };
|
26 | export declare var Type: FunctionConstructor;
|
27 |
|
28 |
|
29 |
|
30 |
|
31 |
|
32 |
|
33 | export interface Type extends Function {
|
34 | }
|
35 |
|
36 |
|
37 |
|
38 | export interface ConcreteType extends Type {
|
39 | new (...args: any[]): any;
|
40 | }
|
41 | export declare function getTypeNameForDebugging(type: Type): string;
|
42 | export declare var Math: any;
|
43 | export declare var Date: DateConstructor;
|
44 | export declare function lockMode(): void;
|
45 |
|
46 |
|
47 |
|
48 |
|
49 |
|
50 |
|
51 |
|
52 |
|
53 |
|
54 | export declare function enableProdMode(): void;
|
55 | export declare function assertionsEnabled(): boolean;
|
56 | export declare function isPresent(obj: any): boolean;
|
57 | export declare function isBlank(obj: any): boolean;
|
58 | export declare function isBoolean(obj: any): boolean;
|
59 | export declare function isNumber(obj: any): boolean;
|
60 | export declare function isString(obj: any): obj is String;
|
61 | export declare function isFunction(obj: any): boolean;
|
62 | export declare function isType(obj: any): boolean;
|
63 | export declare function isStringMap(obj: any): boolean;
|
64 | export declare function isStrictStringMap(obj: any): boolean;
|
65 | export declare function isPromise(obj: any): boolean;
|
66 | export declare function isArray(obj: any): boolean;
|
67 | export declare function isDate(obj: any): obj is Date;
|
68 | export declare function noop(): void;
|
69 | export declare function stringify(token: any): string;
|
70 | export declare function serializeEnum(val: any): number;
|
71 | export declare function deserializeEnum(val: any, values: Map<number, any>): any;
|
72 | export declare function resolveEnumToken(enumValue: any, val: any): string;
|
73 | export declare class StringWrapper {
|
74 | static fromCharCode(code: number): string;
|
75 | static charCodeAt(s: string, index: number): number;
|
76 | static split(s: string, regExp: RegExp): string[];
|
77 | static equals(s: string, s2: string): boolean;
|
78 | static stripLeft(s: string, charVal: string): string;
|
79 | static stripRight(s: string, charVal: string): string;
|
80 | static replace(s: string, from: string, replace: string): string;
|
81 | static replaceAll(s: string, from: RegExp, replace: string): string;
|
82 | static slice<T>(s: string, from?: number, to?: number): string;
|
83 | static replaceAllMapped(s: string, from: RegExp, cb: Function): string;
|
84 | static contains(s: string, substr: string): boolean;
|
85 | static compare(a: string, b: string): number;
|
86 | }
|
87 | export declare class StringJoiner {
|
88 | parts: string[];
|
89 | constructor(parts?: string[]);
|
90 | add(part: string): void;
|
91 | toString(): string;
|
92 | }
|
93 | export declare class NumberParseError extends Error {
|
94 | message: string;
|
95 | name: string;
|
96 | constructor(message: string);
|
97 | toString(): string;
|
98 | }
|
99 | export declare class NumberWrapper {
|
100 | static toFixed(n: number, fractionDigits: number): string;
|
101 | static equal(a: number, b: number): boolean;
|
102 | static parseIntAutoRadix(text: string): number;
|
103 | static parseInt(text: string, radix: number): number;
|
104 | static parseFloat(text: string): number;
|
105 | static NaN: number;
|
106 | static isNaN(value: any): boolean;
|
107 | static isInteger(value: any): boolean;
|
108 | }
|
109 | export declare var RegExp: RegExpConstructor;
|
110 | export declare class RegExpWrapper {
|
111 | static create(regExpStr: string, flags?: string): RegExp;
|
112 | static firstMatch(regExp: RegExp, input: string): RegExpExecArray;
|
113 | static test(regExp: RegExp, input: string): boolean;
|
114 | static matcher(regExp: RegExp, input: string): {
|
115 | re: RegExp;
|
116 | input: string;
|
117 | };
|
118 | static replaceAll(regExp: RegExp, input: string, replace: Function): string;
|
119 | }
|
120 | export declare class RegExpMatcherWrapper {
|
121 | static next(matcher: {
|
122 | re: RegExp;
|
123 | input: string;
|
124 | }): RegExpExecArray;
|
125 | }
|
126 | export declare class FunctionWrapper {
|
127 | static apply(fn: Function, posArgs: any): any;
|
128 | static bind(fn: Function, scope: any): Function;
|
129 | }
|
130 | export declare function looseIdentical(a: any, b: any): boolean;
|
131 | export declare function getMapKey<T>(value: T): T;
|
132 | export declare function normalizeBlank(obj: Object): any;
|
133 | export declare function normalizeBool(obj: boolean): boolean;
|
134 | export declare function isJsObject(o: any): boolean;
|
135 | export declare function print(obj: Error | Object): void;
|
136 | export declare function warn(obj: Error | Object): void;
|
137 | export declare class Json {
|
138 | static parse(s: string): Object;
|
139 | static stringify(data: Object): string;
|
140 | }
|
141 | export declare class DateWrapper {
|
142 | static create(year: number, month?: number, day?: number, hour?: number, minutes?: number, seconds?: number, milliseconds?: number): Date;
|
143 | static fromISOString(str: string): Date;
|
144 | static fromMillis(ms: number): Date;
|
145 | static toMillis(date: Date): number;
|
146 | static now(): Date;
|
147 | static toJson(date: Date): string;
|
148 | }
|
149 | export declare function setValueOnPath(global: any, path: string, value: any): void;
|
150 | export declare function getSymbolIterator(): string | symbol;
|
151 | export declare function evalExpression(sourceUrl: string, expr: string, declarations: string, vars: {
|
152 | [key: string]: any;
|
153 | }): any;
|
154 | export declare function isPrimitive(obj: any): boolean;
|
155 | export declare function hasConstructor(value: Object, type: Type): boolean;
|
156 | export declare function bitWiseOr(values: number[]): number;
|
157 | export declare function bitWiseAnd(values: number[]): number;
|
158 | export declare function escape(s: string): string;
|