1 | |
|
2 | |
|
3 | |
|
4 | |
|
5 | |
|
6 | |
|
7 | |
|
8 | |
|
9 | |
|
10 | |
|
11 | |
|
12 | |
|
13 | |
|
14 | |
|
15 | |
|
16 | |
package org.yaml.snakeyaml.scanner; |
17 | |
|
18 | |
import org.yaml.snakeyaml.error.Mark; |
19 | |
|
20 | |
|
21 | |
|
22 | |
|
23 | |
|
24 | |
|
25 | |
|
26 | |
|
27 | |
|
28 | |
final class SimpleKey { |
29 | |
private int tokenNumber; |
30 | |
private boolean required; |
31 | |
private int index; |
32 | |
private int line; |
33 | |
private int column; |
34 | |
private Mark mark; |
35 | |
|
36 | 376597 | public SimpleKey(int tokenNumber, boolean required, int index, int line, int column, Mark mark) { |
37 | 376597 | this.tokenNumber = tokenNumber; |
38 | 376597 | this.required = required; |
39 | 376597 | this.index = index; |
40 | 376597 | this.line = line; |
41 | 376597 | this.column = column; |
42 | 376597 | this.mark = mark; |
43 | 376597 | } |
44 | |
|
45 | |
public int getTokenNumber() { |
46 | 619531 | return this.tokenNumber; |
47 | |
} |
48 | |
|
49 | |
public int getColumn() { |
50 | 135573 | return this.column; |
51 | |
} |
52 | |
|
53 | |
public Mark getMark() { |
54 | 323200 | return mark; |
55 | |
} |
56 | |
|
57 | |
public int getIndex() { |
58 | 751724 | return index; |
59 | |
} |
60 | |
|
61 | |
public int getLine() { |
62 | 857526 | return line; |
63 | |
} |
64 | |
|
65 | |
public boolean isRequired() { |
66 | 237532 | return required; |
67 | |
} |
68 | |
|
69 | |
@Override |
70 | |
public String toString() { |
71 | 1 | return "SimpleKey - tokenNumber=" + tokenNumber + " required=" + required + " index=" |
72 | |
+ index + " line=" + line + " column=" + column; |
73 | |
} |
74 | |
} |