1 | import { TextDocument } from 'vscode-languageserver-textdocument';
|
2 | import { Range } from 'vscode-languageserver-types';
|
3 | import { Argument } from './argument';
|
4 | export declare class Property {
|
5 | private document;
|
6 | private escapeChar;
|
7 | private readonly range;
|
8 | private readonly nameRange;
|
9 | private readonly name;
|
10 | private readonly assignmentOperatorRange;
|
11 | private readonly assignmentOperator;
|
12 | private readonly valueRange;
|
13 | private readonly value;
|
14 | constructor(document: TextDocument, escapeChar: string, arg: Argument, arg2?: Argument);
|
15 | getRange(): Range;
|
16 | getName(): string;
|
17 | getNameRange(): Range;
|
18 | getValue(): string | null;
|
19 | getValueRange(): Range | null;
|
20 | /**
|
21 | * Retrieves the operator used for delimiting between the name and
|
22 | * value of this property. This will either be the "=" character
|
23 | * or null if a character was not used or if this property has no
|
24 | * value defined.
|
25 | */
|
26 | getAssignmentOperator(): string | null;
|
27 | getAssignmentOperatorRange(): Range | null;
|
28 | /**
|
29 | * Returns the value of this property including any enclosing
|
30 | * single or double quotes and relevant escape characters.
|
31 | * Escaped newlines and its associated contiguous whitespace
|
32 | * characters however will not be returned as they are deemed to
|
33 | * be uninteresting to clients trying to return a Dockerfile.
|
34 | *
|
35 | * @return the unescaped value of this property or null if this
|
36 | * property has no associated value
|
37 | */
|
38 | getUnescapedValue(): string | null;
|
39 | private static getNameRange;
|
40 | private static getValueRange;
|
41 | /**
|
42 | * Returns the actual value of this key-value pair. The value will
|
43 | * have its escape characters removed if applicable. If the value
|
44 | * spans multiple lines and there are comments nested within the
|
45 | * lines, they too will be removed.
|
46 | *
|
47 | * @return the value that this key-value pair will actually be, may
|
48 | * be null if no value is defined, may be the empty string
|
49 | * if the value only consists of whitespace
|
50 | */
|
51 | private static getValue;
|
52 | }
|