1 |
|
2 |
|
3 |
|
4 | export let debug: boolean;
|
5 |
|
6 |
|
7 |
|
8 |
|
9 | export class Source {
|
10 | |
11 |
|
12 |
|
13 | constructor(uri: string, line: number, column: number);
|
14 |
|
15 | /**
|
16 | * Gets the URI of the source document;
|
17 | */
|
18 | uri: string;
|
19 |
|
20 | /**
|
21 | * Gets the line in the source document.
|
22 | */
|
23 | line: number;
|
24 |
|
25 | /**
|
26 | * Gets the position in the source document.
|
27 | */
|
28 | column: number;
|
29 |
|
30 | /**
|
31 | * Get the source of an object.
|
32 | */
|
33 | public static get(object: any): Source;
|
34 |
|
35 | /**
|
36 | * Set the source of an object.
|
37 | */
|
38 | public static set(object: any, src: Source);
|
39 | }
|
40 |
|
41 | /**
|
42 | * An Error class that provides additional context to an error.
|
43 | */
|
44 | export class ScopeError extends Error {
|
45 | |
46 |
|
47 |
|
48 |
|
49 |
|
50 | constructor(child: Error, message?: string);
|
51 | }
|
52 |
|
53 | /**
|
54 | * Represents a scope error providing addiot
|
55 | */
|
56 | export class SourceError extends ScopeError {
|
57 | |
58 |
|
59 |
|
60 |
|
61 |
|
62 |
|
63 | constructor(child: Error, source: Source, message?: string);
|
64 | }
|