prettier-plugin-java 2.6.7 → 2.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/comments.d.ts +17 -0
- package/dist/comments.js +199 -0
- package/dist/index.d.ts +543 -0
- package/dist/index.js +26 -63
- package/dist/options.d.ts +23 -0
- package/dist/options.js +247 -239
- package/dist/parser.d.ts +9 -0
- package/dist/parser.js +24 -4
- package/dist/printer.d.ts +18 -0
- package/dist/printer.js +39 -5
- package/dist/printers/arrays.d.ts +9 -0
- package/dist/printers/arrays.js +8 -24
- package/dist/printers/blocks-and-statements.d.ts +117 -0
- package/dist/printers/blocks-and-statements.js +316 -412
- package/dist/printers/classes.d.ts +157 -0
- package/dist/printers/classes.js +422 -688
- package/dist/printers/expressions.d.ts +134 -0
- package/dist/printers/expressions.js +548 -560
- package/dist/printers/helpers.d.ts +71 -0
- package/dist/printers/helpers.js +233 -0
- package/dist/printers/index.d.ts +2 -0
- package/dist/printers/index.js +13 -0
- package/dist/printers/interfaces.d.ts +62 -0
- package/dist/printers/interfaces.js +146 -211
- package/dist/printers/lexical-structure.d.ts +14 -0
- package/dist/printers/lexical-structure.js +26 -28
- package/dist/printers/names.d.ts +12 -0
- package/dist/printers/names.js +11 -29
- package/dist/printers/packages-and-modules.d.ts +46 -0
- package/dist/printers/packages-and-modules.js +157 -159
- package/dist/printers/types-values-and-variables.d.ts +46 -0
- package/dist/printers/types-values-and-variables.js +86 -149
- package/package.json +5 -8
- package/dist/base-cst-printer.js +0 -55
- package/dist/cst-printer.js +0 -29
- package/dist/printers/comments/comments-utils.js +0 -21
- package/dist/printers/comments/format-comments.js +0 -171
- package/dist/printers/comments/handle-comments.js +0 -102
- package/dist/printers/prettier-builder.js +0 -45
- package/dist/printers/printer-utils.js +0 -598
- package/dist/types/utils.js +0 -20
- package/dist/utils/expressions-utils.js +0 -25
- package/dist/utils/index.js +0 -2
- package/dist/utils/isEmptyDoc.js +0 -4
- package/dist/utils/printArgumentListWithBraces.js +0 -37
- package/dist/utils/printSingleLambdaInvocation.js +0 -18
- package/index.d.ts +0 -4
package/dist/index.js
CHANGED
|
@@ -1,66 +1,29 @@
|
|
|
1
|
-
import parse from "./parser.js";
|
|
2
|
-
import print from "./printer.js";
|
|
3
1
|
import options from "./options.js";
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
name: "Java",
|
|
7
|
-
parsers: ["java"],
|
|
8
|
-
group: "Java",
|
|
9
|
-
tmScope: "text.html.vue", // FIXME
|
|
10
|
-
aceMode: "html", // FIXME
|
|
11
|
-
codemirrorMode: "clike",
|
|
12
|
-
codemirrorMimeType: "text/x-java",
|
|
13
|
-
extensions: [".java"],
|
|
14
|
-
linguistLanguageId: 181,
|
|
15
|
-
vscodeLanguageIds: ["java"]
|
|
16
|
-
}
|
|
17
|
-
];
|
|
18
|
-
function locStart( /* node */) {
|
|
19
|
-
return -1;
|
|
20
|
-
}
|
|
21
|
-
function locEnd( /* node */) {
|
|
22
|
-
return -1;
|
|
23
|
-
}
|
|
24
|
-
function hasPragma(text) {
|
|
25
|
-
return /^\/\*\*[\n][\t\s]+\*\s@(prettier|format)[\n][\t\s]+\*\//.test(text);
|
|
26
|
-
}
|
|
27
|
-
const parsers = {
|
|
28
|
-
java: {
|
|
29
|
-
parse,
|
|
30
|
-
astFormat: "java",
|
|
31
|
-
locStart,
|
|
32
|
-
locEnd,
|
|
33
|
-
hasPragma
|
|
34
|
-
}
|
|
35
|
-
};
|
|
36
|
-
function canAttachComment(node) {
|
|
37
|
-
return node.ast_type && node.ast_type !== "comment";
|
|
38
|
-
}
|
|
39
|
-
function printComment(commentPath) {
|
|
40
|
-
const comment = commentPath.getValue();
|
|
41
|
-
switch (comment.ast_type) {
|
|
42
|
-
case "comment":
|
|
43
|
-
return comment.value;
|
|
44
|
-
default:
|
|
45
|
-
throw new Error("Not a comment: " + JSON.stringify(comment));
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
function clean(ast, newObj) {
|
|
49
|
-
delete newObj.lineno;
|
|
50
|
-
delete newObj.col_offset;
|
|
51
|
-
}
|
|
52
|
-
const printers = {
|
|
53
|
-
java: {
|
|
54
|
-
print,
|
|
55
|
-
// hasPrettierIgnore,
|
|
56
|
-
printComment,
|
|
57
|
-
canAttachComment,
|
|
58
|
-
massageAstNode: clean
|
|
59
|
-
}
|
|
60
|
-
};
|
|
2
|
+
import parser from "./parser.js";
|
|
3
|
+
import printer from "./printer.js";
|
|
61
4
|
export default {
|
|
62
|
-
languages
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
5
|
+
languages: [
|
|
6
|
+
{
|
|
7
|
+
name: "Java",
|
|
8
|
+
parsers: ["java"],
|
|
9
|
+
group: "Java",
|
|
10
|
+
tmScope: "source.java",
|
|
11
|
+
aceMode: "java",
|
|
12
|
+
codemirrorMode: "clike",
|
|
13
|
+
codemirrorMimeType: "text/x-java",
|
|
14
|
+
extensions: [".java"],
|
|
15
|
+
linguistLanguageId: 181,
|
|
16
|
+
vscodeLanguageIds: ["java"]
|
|
17
|
+
}
|
|
18
|
+
],
|
|
19
|
+
parsers: {
|
|
20
|
+
java: parser
|
|
21
|
+
},
|
|
22
|
+
printers: {
|
|
23
|
+
java: printer
|
|
24
|
+
},
|
|
25
|
+
options,
|
|
26
|
+
defaultOptions: {
|
|
27
|
+
arrowParens: "avoid"
|
|
28
|
+
}
|
|
66
29
|
};
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
declare const _default: {
|
|
2
|
+
entrypoint: {
|
|
3
|
+
type: "choice";
|
|
4
|
+
category: string;
|
|
5
|
+
default: string;
|
|
6
|
+
choices: {
|
|
7
|
+
value: string;
|
|
8
|
+
description: string;
|
|
9
|
+
}[];
|
|
10
|
+
description: string;
|
|
11
|
+
};
|
|
12
|
+
trailingComma: {
|
|
13
|
+
type: "choice";
|
|
14
|
+
category: string;
|
|
15
|
+
default: string;
|
|
16
|
+
choices: {
|
|
17
|
+
value: string;
|
|
18
|
+
description: string;
|
|
19
|
+
}[];
|
|
20
|
+
description: string;
|
|
21
|
+
};
|
|
22
|
+
};
|
|
23
|
+
export default _default;
|
package/dist/options.js
CHANGED
|
@@ -5,244 +5,248 @@ export default {
|
|
|
5
5
|
default: "compilationUnit",
|
|
6
6
|
// sed -nr 's/.*\.RULE\(([^,]+),.*/\1/p' $(ls path/to/java-parser/rules/folder/*)
|
|
7
7
|
choices: [
|
|
8
|
-
{ value: "arrayInitializer" },
|
|
9
|
-
{ value: "variableInitializerList" },
|
|
10
|
-
{ value: "block" },
|
|
11
|
-
{ value: "blockStatements" },
|
|
12
|
-
{ value: "blockStatement" },
|
|
13
|
-
{ value: "localVariableDeclarationStatement" },
|
|
14
|
-
{ value: "localVariableDeclaration" },
|
|
15
|
-
{ value: "localVariableType" },
|
|
16
|
-
{ value: "statement" },
|
|
17
|
-
{ value: "statementWithoutTrailingSubstatement" },
|
|
18
|
-
{ value: "emptyStatement" },
|
|
19
|
-
{ value: "labeledStatement" },
|
|
20
|
-
{ value: "expressionStatement" },
|
|
21
|
-
{ value: "statementExpression" },
|
|
22
|
-
{ value: "ifStatement" },
|
|
23
|
-
{ value: "assertStatement" },
|
|
24
|
-
{ value: "switchStatement" },
|
|
25
|
-
{ value: "switchBlock" },
|
|
26
|
-
{ value: "switchBlockStatementGroup" },
|
|
27
|
-
{ value: "switchLabel" },
|
|
28
|
-
{ value: "switchRule" },
|
|
29
|
-
{ value: "caseConstant" },
|
|
30
|
-
{ value: "casePattern" },
|
|
31
|
-
{ value: "whileStatement" },
|
|
32
|
-
{ value: "doStatement" },
|
|
33
|
-
{ value: "forStatement" },
|
|
34
|
-
{ value: "basicForStatement" },
|
|
35
|
-
{ value: "forInit" },
|
|
36
|
-
{ value: "forUpdate" },
|
|
37
|
-
{ value: "statementExpressionList" },
|
|
38
|
-
{ value: "enhancedForStatement" },
|
|
39
|
-
{ value: "breakStatement" },
|
|
40
|
-
{ value: "continueStatement" },
|
|
41
|
-
{ value: "returnStatement" },
|
|
42
|
-
{ value: "throwStatement" },
|
|
43
|
-
{ value: "synchronizedStatement" },
|
|
44
|
-
{ value: "tryStatement" },
|
|
45
|
-
{ value: "catches" },
|
|
46
|
-
{ value: "catchClause" },
|
|
47
|
-
{ value: "catchFormalParameter" },
|
|
48
|
-
{ value: "catchType" },
|
|
49
|
-
{ value: "finally" },
|
|
50
|
-
{ value: "tryWithResourcesStatement" },
|
|
51
|
-
{ value: "resourceSpecification" },
|
|
52
|
-
{ value: "resourceList" },
|
|
53
|
-
{ value: "resource" },
|
|
54
|
-
{ value: "yieldStatement" },
|
|
55
|
-
{ value: "variableAccess" },
|
|
56
|
-
{ value: "classDeclaration" },
|
|
57
|
-
{ value: "normalClassDeclaration" },
|
|
58
|
-
{ value: "classModifier" },
|
|
59
|
-
{ value: "typeParameters" },
|
|
60
|
-
{ value: "typeParameterList" },
|
|
61
|
-
{ value: "classExtends" },
|
|
62
|
-
{ value: "classImplements" },
|
|
63
|
-
{ value: "interfaceTypeList" },
|
|
64
|
-
{ value: "classPermits" },
|
|
65
|
-
{ value: "classBody" },
|
|
66
|
-
{ value: "classBodyDeclaration" },
|
|
67
|
-
{ value: "classMemberDeclaration" },
|
|
68
|
-
{ value: "fieldDeclaration" },
|
|
69
|
-
{ value: "fieldModifier" },
|
|
70
|
-
{ value: "variableDeclaratorList" },
|
|
71
|
-
{ value: "variableDeclarator" },
|
|
72
|
-
{ value: "variableDeclaratorId" },
|
|
73
|
-
{ value: "variableInitializer" },
|
|
74
|
-
{ value: "unannType" },
|
|
75
|
-
{ value: "unannPrimitiveTypeWithOptionalDimsSuffix" },
|
|
76
|
-
{ value: "unannPrimitiveType" },
|
|
77
|
-
{ value: "unannReferenceType" },
|
|
78
|
-
{ value: "unannClassOrInterfaceType" },
|
|
79
|
-
{ value: "unannClassType" },
|
|
80
|
-
{ value: "unannInterfaceType" },
|
|
81
|
-
{ value: "unannTypeVariable" },
|
|
82
|
-
{ value: "methodDeclaration" },
|
|
83
|
-
{ value: "methodModifier" },
|
|
84
|
-
{ value: "methodHeader" },
|
|
85
|
-
{ value: "result" },
|
|
86
|
-
{ value: "methodDeclarator" },
|
|
87
|
-
{ value: "receiverParameter" },
|
|
88
|
-
{ value: "formalParameterList" },
|
|
89
|
-
{ value: "formalParameter" },
|
|
90
|
-
{ value: "variableParaRegularParameter" },
|
|
91
|
-
{ value: "variableArityParameter" },
|
|
92
|
-
{ value: "variableModifier" },
|
|
93
|
-
{ value: "throws" },
|
|
94
|
-
{ value: "exceptionTypeList" },
|
|
95
|
-
{ value: "exceptionType" },
|
|
96
|
-
{ value: "methodBody" },
|
|
97
|
-
{ value: "instanceInitializer" },
|
|
98
|
-
{ value: "staticInitializer" },
|
|
99
|
-
{ value: "constructorDeclaration" },
|
|
100
|
-
{ value: "constructorModifier" },
|
|
101
|
-
{ value: "constructorDeclarator" },
|
|
102
|
-
{ value: "simpleTypeName" },
|
|
103
|
-
{ value: "constructorBody" },
|
|
104
|
-
{ value: "explicitConstructorInvocation" },
|
|
105
|
-
{ value: "unqualifiedExplicitConstructorInvocation" },
|
|
106
|
-
{ value: "qualifiedExplicitConstructorInvocation" },
|
|
107
|
-
{ value: "enumDeclaration" },
|
|
108
|
-
{ value: "enumBody" },
|
|
109
|
-
{ value: "enumConstantList" },
|
|
110
|
-
{ value: "enumConstant" },
|
|
111
|
-
{ value: "enumConstantModifier" },
|
|
112
|
-
{ value: "enumBodyDeclarations" },
|
|
113
|
-
{ value: "recordDeclaration" },
|
|
114
|
-
{ value: "recordHeader" },
|
|
115
|
-
{ value: "recordComponentList" },
|
|
116
|
-
{ value: "recordComponent" },
|
|
117
|
-
{ value: "variableArityRecordComponent" },
|
|
118
|
-
{ value: "recordComponentModifier" },
|
|
119
|
-
{ value: "recordBody" },
|
|
120
|
-
{ value: "recordBodyDeclaration" },
|
|
121
|
-
{ value: "compactConstructorDeclaration" },
|
|
122
|
-
{ value: "isDims" },
|
|
123
|
-
{ value: "expression" },
|
|
124
|
-
{ value: "lambdaExpression" },
|
|
125
|
-
{ value: "lambdaParameters" },
|
|
126
|
-
{ value: "lambdaParametersWithBraces" },
|
|
127
|
-
{ value: "lambdaParameterList" },
|
|
128
|
-
{ value: "conciseLambdaParameterList" },
|
|
129
|
-
{ value: "normalLambdaParameterList" },
|
|
130
|
-
{ value: "normalLambdaParameter" },
|
|
131
|
-
{ value: "regularLambdaParameter" },
|
|
132
|
-
{ value: "lambdaParameterType" },
|
|
133
|
-
{ value: "conciseLambdaParameter" },
|
|
134
|
-
{ value: "lambdaBody" },
|
|
135
|
-
{ value: "conditionalExpression" },
|
|
136
|
-
{ value: "binaryExpression" },
|
|
137
|
-
{ value: "unaryExpression" },
|
|
138
|
-
{ value: "unaryExpressionNotPlusMinus" },
|
|
139
|
-
{ value: "primary" },
|
|
140
|
-
{ value: "primaryPrefix" },
|
|
141
|
-
{ value: "primarySuffix" },
|
|
142
|
-
{ value: "fqnOrRefType" },
|
|
143
|
-
{ value: "fqnOrRefTypePartRest" },
|
|
144
|
-
{ value: "fqnOrRefTypePartCommon" },
|
|
145
|
-
{ value: "fqnOrRefTypePartFirst" },
|
|
146
|
-
{ value: "parenthesisExpression" },
|
|
147
|
-
{ value: "castExpression" },
|
|
148
|
-
{ value: "primitiveCastExpression" },
|
|
149
|
-
{ value: "referenceTypeCastExpression" },
|
|
150
|
-
{ value: "newExpression" },
|
|
151
|
-
{ value: "unqualifiedClassInstanceCreationExpression" },
|
|
152
|
-
{ value: "classOrInterfaceTypeToInstantiate" },
|
|
153
|
-
{ value: "typeArgumentsOrDiamond" },
|
|
154
|
-
{ value: "diamond" },
|
|
155
|
-
{ value: "methodInvocationSuffix" },
|
|
156
|
-
{ value: "argumentList" },
|
|
157
|
-
{ value: "arrayCreationExpression" },
|
|
158
|
-
{
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
{ value: "
|
|
163
|
-
{ value: "
|
|
164
|
-
{ value: "
|
|
165
|
-
{ value: "
|
|
166
|
-
{ value: "
|
|
167
|
-
{ value: "
|
|
168
|
-
{ value: "
|
|
169
|
-
{ value: "
|
|
170
|
-
{ value: "
|
|
171
|
-
{ value: "
|
|
172
|
-
{ value: "
|
|
173
|
-
{ value: "
|
|
174
|
-
{ value: "
|
|
175
|
-
{ value: "
|
|
176
|
-
{ value: "
|
|
177
|
-
{ value: "
|
|
178
|
-
{ value: "
|
|
179
|
-
{ value: "
|
|
180
|
-
{ value: "
|
|
181
|
-
{ value: "
|
|
182
|
-
{ value: "
|
|
183
|
-
{ value: "
|
|
184
|
-
{ value: "
|
|
185
|
-
{ value: "
|
|
186
|
-
{ value: "
|
|
187
|
-
{ value: "
|
|
188
|
-
{ value: "
|
|
189
|
-
{ value: "
|
|
190
|
-
{ value: "
|
|
191
|
-
{ value: "
|
|
192
|
-
{ value: "
|
|
193
|
-
{ value: "
|
|
194
|
-
{ value: "
|
|
195
|
-
{ value: "
|
|
196
|
-
{ value: "
|
|
197
|
-
{ value: "
|
|
198
|
-
{ value: "
|
|
199
|
-
{ value: "
|
|
200
|
-
{ value: "
|
|
201
|
-
{ value: "
|
|
202
|
-
{ value: "
|
|
203
|
-
{ value: "
|
|
204
|
-
{ value: "
|
|
205
|
-
{ value: "
|
|
206
|
-
{ value: "
|
|
207
|
-
{ value: "
|
|
208
|
-
{ value: "
|
|
209
|
-
{ value: "
|
|
210
|
-
{ value: "
|
|
211
|
-
{ value: "
|
|
212
|
-
{ value: "
|
|
213
|
-
{ value: "
|
|
214
|
-
{ value: "
|
|
215
|
-
{ value: "
|
|
216
|
-
{ value: "
|
|
217
|
-
{ value: "
|
|
218
|
-
{ value: "
|
|
219
|
-
{ value: "
|
|
220
|
-
{ value: "
|
|
221
|
-
{ value: "
|
|
222
|
-
{ value: "
|
|
223
|
-
{ value: "
|
|
224
|
-
{ value: "
|
|
225
|
-
{ value: "
|
|
226
|
-
{ value: "
|
|
227
|
-
{ value: "
|
|
228
|
-
{ value: "
|
|
229
|
-
{ value: "
|
|
230
|
-
{ value: "
|
|
231
|
-
{ value: "
|
|
232
|
-
{ value: "
|
|
233
|
-
{ value: "
|
|
234
|
-
{ value: "
|
|
235
|
-
{ value: "
|
|
236
|
-
{ value: "
|
|
237
|
-
{ value: "
|
|
238
|
-
{ value: "
|
|
239
|
-
{ value: "
|
|
240
|
-
{ value: "
|
|
241
|
-
{ value: "
|
|
242
|
-
{ value: "
|
|
243
|
-
{ value: "
|
|
244
|
-
{ value: "
|
|
245
|
-
{ value: "
|
|
8
|
+
{ value: "arrayInitializer", description: "" },
|
|
9
|
+
{ value: "variableInitializerList", description: "" },
|
|
10
|
+
{ value: "block", description: "" },
|
|
11
|
+
{ value: "blockStatements", description: "" },
|
|
12
|
+
{ value: "blockStatement", description: "" },
|
|
13
|
+
{ value: "localVariableDeclarationStatement", description: "" },
|
|
14
|
+
{ value: "localVariableDeclaration", description: "" },
|
|
15
|
+
{ value: "localVariableType", description: "" },
|
|
16
|
+
{ value: "statement", description: "" },
|
|
17
|
+
{ value: "statementWithoutTrailingSubstatement", description: "" },
|
|
18
|
+
{ value: "emptyStatement", description: "" },
|
|
19
|
+
{ value: "labeledStatement", description: "" },
|
|
20
|
+
{ value: "expressionStatement", description: "" },
|
|
21
|
+
{ value: "statementExpression", description: "" },
|
|
22
|
+
{ value: "ifStatement", description: "" },
|
|
23
|
+
{ value: "assertStatement", description: "" },
|
|
24
|
+
{ value: "switchStatement", description: "" },
|
|
25
|
+
{ value: "switchBlock", description: "" },
|
|
26
|
+
{ value: "switchBlockStatementGroup", description: "" },
|
|
27
|
+
{ value: "switchLabel", description: "" },
|
|
28
|
+
{ value: "switchRule", description: "" },
|
|
29
|
+
{ value: "caseConstant", description: "" },
|
|
30
|
+
{ value: "casePattern", description: "" },
|
|
31
|
+
{ value: "whileStatement", description: "" },
|
|
32
|
+
{ value: "doStatement", description: "" },
|
|
33
|
+
{ value: "forStatement", description: "" },
|
|
34
|
+
{ value: "basicForStatement", description: "" },
|
|
35
|
+
{ value: "forInit", description: "" },
|
|
36
|
+
{ value: "forUpdate", description: "" },
|
|
37
|
+
{ value: "statementExpressionList", description: "" },
|
|
38
|
+
{ value: "enhancedForStatement", description: "" },
|
|
39
|
+
{ value: "breakStatement", description: "" },
|
|
40
|
+
{ value: "continueStatement", description: "" },
|
|
41
|
+
{ value: "returnStatement", description: "" },
|
|
42
|
+
{ value: "throwStatement", description: "" },
|
|
43
|
+
{ value: "synchronizedStatement", description: "" },
|
|
44
|
+
{ value: "tryStatement", description: "" },
|
|
45
|
+
{ value: "catches", description: "" },
|
|
46
|
+
{ value: "catchClause", description: "" },
|
|
47
|
+
{ value: "catchFormalParameter", description: "" },
|
|
48
|
+
{ value: "catchType", description: "" },
|
|
49
|
+
{ value: "finally", description: "" },
|
|
50
|
+
{ value: "tryWithResourcesStatement", description: "" },
|
|
51
|
+
{ value: "resourceSpecification", description: "" },
|
|
52
|
+
{ value: "resourceList", description: "" },
|
|
53
|
+
{ value: "resource", description: "" },
|
|
54
|
+
{ value: "yieldStatement", description: "" },
|
|
55
|
+
{ value: "variableAccess", description: "" },
|
|
56
|
+
{ value: "classDeclaration", description: "" },
|
|
57
|
+
{ value: "normalClassDeclaration", description: "" },
|
|
58
|
+
{ value: "classModifier", description: "" },
|
|
59
|
+
{ value: "typeParameters", description: "" },
|
|
60
|
+
{ value: "typeParameterList", description: "" },
|
|
61
|
+
{ value: "classExtends", description: "" },
|
|
62
|
+
{ value: "classImplements", description: "" },
|
|
63
|
+
{ value: "interfaceTypeList", description: "" },
|
|
64
|
+
{ value: "classPermits", description: "" },
|
|
65
|
+
{ value: "classBody", description: "" },
|
|
66
|
+
{ value: "classBodyDeclaration", description: "" },
|
|
67
|
+
{ value: "classMemberDeclaration", description: "" },
|
|
68
|
+
{ value: "fieldDeclaration", description: "" },
|
|
69
|
+
{ value: "fieldModifier", description: "" },
|
|
70
|
+
{ value: "variableDeclaratorList", description: "" },
|
|
71
|
+
{ value: "variableDeclarator", description: "" },
|
|
72
|
+
{ value: "variableDeclaratorId", description: "" },
|
|
73
|
+
{ value: "variableInitializer", description: "" },
|
|
74
|
+
{ value: "unannType", description: "" },
|
|
75
|
+
{ value: "unannPrimitiveTypeWithOptionalDimsSuffix", description: "" },
|
|
76
|
+
{ value: "unannPrimitiveType", description: "" },
|
|
77
|
+
{ value: "unannReferenceType", description: "" },
|
|
78
|
+
{ value: "unannClassOrInterfaceType", description: "" },
|
|
79
|
+
{ value: "unannClassType", description: "" },
|
|
80
|
+
{ value: "unannInterfaceType", description: "" },
|
|
81
|
+
{ value: "unannTypeVariable", description: "" },
|
|
82
|
+
{ value: "methodDeclaration", description: "" },
|
|
83
|
+
{ value: "methodModifier", description: "" },
|
|
84
|
+
{ value: "methodHeader", description: "" },
|
|
85
|
+
{ value: "result", description: "" },
|
|
86
|
+
{ value: "methodDeclarator", description: "" },
|
|
87
|
+
{ value: "receiverParameter", description: "" },
|
|
88
|
+
{ value: "formalParameterList", description: "" },
|
|
89
|
+
{ value: "formalParameter", description: "" },
|
|
90
|
+
{ value: "variableParaRegularParameter", description: "" },
|
|
91
|
+
{ value: "variableArityParameter", description: "" },
|
|
92
|
+
{ value: "variableModifier", description: "" },
|
|
93
|
+
{ value: "throws", description: "" },
|
|
94
|
+
{ value: "exceptionTypeList", description: "" },
|
|
95
|
+
{ value: "exceptionType", description: "" },
|
|
96
|
+
{ value: "methodBody", description: "" },
|
|
97
|
+
{ value: "instanceInitializer", description: "" },
|
|
98
|
+
{ value: "staticInitializer", description: "" },
|
|
99
|
+
{ value: "constructorDeclaration", description: "" },
|
|
100
|
+
{ value: "constructorModifier", description: "" },
|
|
101
|
+
{ value: "constructorDeclarator", description: "" },
|
|
102
|
+
{ value: "simpleTypeName", description: "" },
|
|
103
|
+
{ value: "constructorBody", description: "" },
|
|
104
|
+
{ value: "explicitConstructorInvocation", description: "" },
|
|
105
|
+
{ value: "unqualifiedExplicitConstructorInvocation", description: "" },
|
|
106
|
+
{ value: "qualifiedExplicitConstructorInvocation", description: "" },
|
|
107
|
+
{ value: "enumDeclaration", description: "" },
|
|
108
|
+
{ value: "enumBody", description: "" },
|
|
109
|
+
{ value: "enumConstantList", description: "" },
|
|
110
|
+
{ value: "enumConstant", description: "" },
|
|
111
|
+
{ value: "enumConstantModifier", description: "" },
|
|
112
|
+
{ value: "enumBodyDeclarations", description: "" },
|
|
113
|
+
{ value: "recordDeclaration", description: "" },
|
|
114
|
+
{ value: "recordHeader", description: "" },
|
|
115
|
+
{ value: "recordComponentList", description: "" },
|
|
116
|
+
{ value: "recordComponent", description: "" },
|
|
117
|
+
{ value: "variableArityRecordComponent", description: "" },
|
|
118
|
+
{ value: "recordComponentModifier", description: "" },
|
|
119
|
+
{ value: "recordBody", description: "" },
|
|
120
|
+
{ value: "recordBodyDeclaration", description: "" },
|
|
121
|
+
{ value: "compactConstructorDeclaration", description: "" },
|
|
122
|
+
{ value: "isDims", description: "" },
|
|
123
|
+
{ value: "expression", description: "" },
|
|
124
|
+
{ value: "lambdaExpression", description: "" },
|
|
125
|
+
{ value: "lambdaParameters", description: "" },
|
|
126
|
+
{ value: "lambdaParametersWithBraces", description: "" },
|
|
127
|
+
{ value: "lambdaParameterList", description: "" },
|
|
128
|
+
{ value: "conciseLambdaParameterList", description: "" },
|
|
129
|
+
{ value: "normalLambdaParameterList", description: "" },
|
|
130
|
+
{ value: "normalLambdaParameter", description: "" },
|
|
131
|
+
{ value: "regularLambdaParameter", description: "" },
|
|
132
|
+
{ value: "lambdaParameterType", description: "" },
|
|
133
|
+
{ value: "conciseLambdaParameter", description: "" },
|
|
134
|
+
{ value: "lambdaBody", description: "" },
|
|
135
|
+
{ value: "conditionalExpression", description: "" },
|
|
136
|
+
{ value: "binaryExpression", description: "" },
|
|
137
|
+
{ value: "unaryExpression", description: "" },
|
|
138
|
+
{ value: "unaryExpressionNotPlusMinus", description: "" },
|
|
139
|
+
{ value: "primary", description: "" },
|
|
140
|
+
{ value: "primaryPrefix", description: "" },
|
|
141
|
+
{ value: "primarySuffix", description: "" },
|
|
142
|
+
{ value: "fqnOrRefType", description: "" },
|
|
143
|
+
{ value: "fqnOrRefTypePartRest", description: "" },
|
|
144
|
+
{ value: "fqnOrRefTypePartCommon", description: "" },
|
|
145
|
+
{ value: "fqnOrRefTypePartFirst", description: "" },
|
|
146
|
+
{ value: "parenthesisExpression", description: "" },
|
|
147
|
+
{ value: "castExpression", description: "" },
|
|
148
|
+
{ value: "primitiveCastExpression", description: "" },
|
|
149
|
+
{ value: "referenceTypeCastExpression", description: "" },
|
|
150
|
+
{ value: "newExpression", description: "" },
|
|
151
|
+
{ value: "unqualifiedClassInstanceCreationExpression", description: "" },
|
|
152
|
+
{ value: "classOrInterfaceTypeToInstantiate", description: "" },
|
|
153
|
+
{ value: "typeArgumentsOrDiamond", description: "" },
|
|
154
|
+
{ value: "diamond", description: "" },
|
|
155
|
+
{ value: "methodInvocationSuffix", description: "" },
|
|
156
|
+
{ value: "argumentList", description: "" },
|
|
157
|
+
{ value: "arrayCreationExpression", description: "" },
|
|
158
|
+
{
|
|
159
|
+
value: "arrayCreationExpressionWithoutInitializerSuffix",
|
|
160
|
+
description: ""
|
|
161
|
+
},
|
|
162
|
+
{ value: "arrayCreationWithInitializerSuffix", description: "" },
|
|
163
|
+
{ value: "dimExprs", description: "" },
|
|
164
|
+
{ value: "dimExpr", description: "" },
|
|
165
|
+
{ value: "classLiteralSuffix", description: "" },
|
|
166
|
+
{ value: "arrayAccessSuffix", description: "" },
|
|
167
|
+
{ value: "methodReferenceSuffix", description: "" },
|
|
168
|
+
{ value: "templateArgument", description: "" },
|
|
169
|
+
{ value: "template", description: "" },
|
|
170
|
+
{ value: "stringTemplate", description: "" },
|
|
171
|
+
{ value: "textBlockTemplate", description: "" },
|
|
172
|
+
{ value: "embeddedExpression", description: "" },
|
|
173
|
+
{ value: "pattern", description: "" },
|
|
174
|
+
{ value: "typePattern", description: "" },
|
|
175
|
+
{ value: "recordPattern", description: "" },
|
|
176
|
+
{ value: "componentPatternList", description: "" },
|
|
177
|
+
{ value: "componentPattern", description: "" },
|
|
178
|
+
{ value: "matchAllPattern", description: "" },
|
|
179
|
+
{ value: "guard", description: "" },
|
|
180
|
+
{ value: "isRefTypeInMethodRef", description: "" },
|
|
181
|
+
{ value: "interfaceDeclaration", description: "" },
|
|
182
|
+
{ value: "normalInterfaceDeclaration", description: "" },
|
|
183
|
+
{ value: "interfaceModifier", description: "" },
|
|
184
|
+
{ value: "interfaceExtends", description: "" },
|
|
185
|
+
{ value: "interfacePermits", description: "" },
|
|
186
|
+
{ value: "interfaceBody", description: "" },
|
|
187
|
+
{ value: "interfaceMemberDeclaration", description: "" },
|
|
188
|
+
{ value: "constantDeclaration", description: "" },
|
|
189
|
+
{ value: "constantModifier", description: "" },
|
|
190
|
+
{ value: "interfaceMethodDeclaration", description: "" },
|
|
191
|
+
{ value: "interfaceMethodModifier", description: "" },
|
|
192
|
+
{ value: "annotationInterfaceDeclaration", description: "" },
|
|
193
|
+
{ value: "annotationInterfaceBody", description: "" },
|
|
194
|
+
{ value: "annotationInterfaceMemberDeclaration", description: "" },
|
|
195
|
+
{ value: "annotationInterfaceElementDeclaration", description: "" },
|
|
196
|
+
{ value: "annotationInterfaceElementModifier", description: "" },
|
|
197
|
+
{ value: "defaultValue", description: "" },
|
|
198
|
+
{ value: "annotation", description: "" },
|
|
199
|
+
{ value: "elementValuePairList", description: "" },
|
|
200
|
+
{ value: "elementValuePair", description: "" },
|
|
201
|
+
{ value: "elementValue", description: "" },
|
|
202
|
+
{ value: "elementValueArrayInitializer", description: "" },
|
|
203
|
+
{ value: "elementValueList", description: "" },
|
|
204
|
+
{ value: "literal", description: "" },
|
|
205
|
+
{ value: "integerLiteral", description: "" },
|
|
206
|
+
{ value: "floatingPointLiteral", description: "" },
|
|
207
|
+
{ value: "booleanLiteral", description: "" },
|
|
208
|
+
{ value: "shiftOperator", description: "" },
|
|
209
|
+
{ value: "moduleName", description: "" },
|
|
210
|
+
{ value: "packageName", description: "" },
|
|
211
|
+
{ value: "typeName", description: "" },
|
|
212
|
+
{ value: "expressionName", description: "" },
|
|
213
|
+
{ value: "methodName", description: "" },
|
|
214
|
+
{ value: "packageOrTypeName", description: "" },
|
|
215
|
+
{ value: "ambiguousName", description: "" },
|
|
216
|
+
{ value: "compilationUnit", description: "" },
|
|
217
|
+
{ value: "ordinaryCompilationUnit", description: "" },
|
|
218
|
+
{ value: "modularCompilationUnit", description: "" },
|
|
219
|
+
{ value: "packageDeclaration", description: "" },
|
|
220
|
+
{ value: "packageModifier", description: "" },
|
|
221
|
+
{ value: "importDeclaration", description: "" },
|
|
222
|
+
{ value: "typeDeclaration", description: "" },
|
|
223
|
+
{ value: "moduleDeclaration", description: "" },
|
|
224
|
+
{ value: "moduleDirective", description: "" },
|
|
225
|
+
{ value: "requiresModuleDirective", description: "" },
|
|
226
|
+
{ value: "exportsModuleDirective", description: "" },
|
|
227
|
+
{ value: "opensModuleDirective", description: "" },
|
|
228
|
+
{ value: "usesModuleDirective", description: "" },
|
|
229
|
+
{ value: "providesModuleDirective", description: "" },
|
|
230
|
+
{ value: "requiresModifier", description: "" },
|
|
231
|
+
{ value: "primitiveType", description: "" },
|
|
232
|
+
{ value: "numericType", description: "" },
|
|
233
|
+
{ value: "integralType", description: "" },
|
|
234
|
+
{ value: "floatingPointType", description: "" },
|
|
235
|
+
{ value: "referenceType", description: "" },
|
|
236
|
+
{ value: "classOrInterfaceType", description: "" },
|
|
237
|
+
{ value: "classType", description: "" },
|
|
238
|
+
{ value: "interfaceType", description: "" },
|
|
239
|
+
{ value: "typeVariable", description: "" },
|
|
240
|
+
{ value: "dims", description: "" },
|
|
241
|
+
{ value: "typeParameter", description: "" },
|
|
242
|
+
{ value: "typeParameterModifier", description: "" },
|
|
243
|
+
{ value: "typeBound", description: "" },
|
|
244
|
+
{ value: "additionalBound", description: "" },
|
|
245
|
+
{ value: "typeArguments", description: "" },
|
|
246
|
+
{ value: "typeArgumentList", description: "" },
|
|
247
|
+
{ value: "typeArgument", description: "" },
|
|
248
|
+
{ value: "wildcard", description: "" },
|
|
249
|
+
{ value: "wildcardBounds", description: "" }
|
|
246
250
|
],
|
|
247
251
|
description: "Prettify from the entrypoint, allowing to use prettier on snippet."
|
|
248
252
|
},
|
|
@@ -250,7 +254,11 @@ export default {
|
|
|
250
254
|
type: "choice",
|
|
251
255
|
category: "Java",
|
|
252
256
|
default: "all",
|
|
253
|
-
choices: [
|
|
257
|
+
choices: [
|
|
258
|
+
{ value: "all", description: "" },
|
|
259
|
+
{ value: "es5", description: "" },
|
|
260
|
+
{ value: "none", description: "" }
|
|
261
|
+
],
|
|
254
262
|
description: "Print trailing commas wherever possible when multi-line."
|
|
255
263
|
}
|
|
256
264
|
};
|