author | jjg |
Fri, 21 Aug 2009 11:25:45 -0700 | |
changeset 3660 | ee583c342a41 |
parent 2212 | 1d3dc0e0ba0c |
child 3995 | 73af8b6fb8bc |
permissions | -rw-r--r-- |
10 | 1 |
/* |
2212 | 2 |
* Copyright 1999-2009 Sun Microsystems, Inc. All Rights Reserved. |
10 | 3 |
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 |
* |
|
5 |
* This code is free software; you can redistribute it and/or modify it |
|
6 |
* under the terms of the GNU General Public License version 2 only, as |
|
7 |
* published by the Free Software Foundation. Sun designates this |
|
8 |
* particular file as subject to the "Classpath" exception as provided |
|
9 |
* by Sun in the LICENSE file that accompanied this code. |
|
10 |
* |
|
11 |
* This code is distributed in the hope that it will be useful, but WITHOUT |
|
12 |
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
|
13 |
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
|
14 |
* version 2 for more details (a copy is included in the LICENSE file that |
|
15 |
* accompanied this code). |
|
16 |
* |
|
17 |
* You should have received a copy of the GNU General Public License version |
|
18 |
* 2 along with this work; if not, write to the Free Software Foundation, |
|
19 |
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
|
20 |
* |
|
21 |
* Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, |
|
22 |
* CA 95054 USA or visit www.sun.com if you need additional information or |
|
23 |
* have any questions. |
|
24 |
*/ |
|
25 |
||
26 |
package com.sun.tools.javac.util; |
|
27 |
||
28 |
import java.io.*; |
|
1866 | 29 |
import java.util.Arrays; |
10 | 30 |
import java.util.HashSet; |
31 |
import java.util.Map; |
|
32 |
import java.util.Set; |
|
33 |
import javax.tools.DiagnosticListener; |
|
34 |
import javax.tools.JavaFileObject; |
|
731
1dd22bdb9ca5
6714364: refactor javac File handling code into new javac.file package
jjg
parents:
167
diff
changeset
|
35 |
|
1dd22bdb9ca5
6714364: refactor javac File handling code into new javac.file package
jjg
parents:
167
diff
changeset
|
36 |
import com.sun.tools.javac.file.JavacFileManager; |
10 | 37 |
import com.sun.tools.javac.tree.JCTree; |
942 | 38 |
import com.sun.tools.javac.api.DiagnosticFormatter; |
10 | 39 |
import com.sun.tools.javac.util.JCDiagnostic.DiagnosticPosition; |
40 |
import com.sun.tools.javac.util.JCDiagnostic.DiagnosticType; |
|
41 |
||
42 |
/** A class for error logs. Reports errors and warnings, and |
|
43 |
* keeps track of error numbers and positions. |
|
44 |
* |
|
45 |
* <p><b>This is NOT part of any API supported by Sun Microsystems. If |
|
46 |
* you write code that depends on this, you do so at your own risk. |
|
47 |
* This code and its internal interfaces are subject to change or |
|
48 |
* deletion without notice.</b> |
|
49 |
*/ |
|
867 | 50 |
public class Log extends AbstractLog { |
10 | 51 |
/** The context key for the log. */ |
52 |
public static final Context.Key<Log> logKey |
|
53 |
= new Context.Key<Log>(); |
|
54 |
||
55 |
/** The context key for the output PrintWriter. */ |
|
56 |
public static final Context.Key<PrintWriter> outKey = |
|
57 |
new Context.Key<PrintWriter>(); |
|
58 |
||
59 |
//@Deprecated |
|
60 |
public final PrintWriter errWriter; |
|
61 |
||
62 |
//@Deprecated |
|
63 |
public final PrintWriter warnWriter; |
|
64 |
||
65 |
//@Deprecated |
|
66 |
public final PrintWriter noticeWriter; |
|
67 |
||
68 |
/** The maximum number of errors/warnings that are reported. |
|
69 |
*/ |
|
70 |
public final int MaxErrors; |
|
71 |
public final int MaxWarnings; |
|
72 |
||
73 |
/** Switch: prompt user on each error. |
|
74 |
*/ |
|
75 |
public boolean promptOnError; |
|
76 |
||
77 |
/** Switch: emit warning messages. |
|
78 |
*/ |
|
79 |
public boolean emitWarnings; |
|
80 |
||
3660 | 81 |
/** Switch: suppress note messages. |
82 |
*/ |
|
83 |
public boolean suppressNotes; |
|
84 |
||
10 | 85 |
/** Print stack trace on errors? |
86 |
*/ |
|
87 |
public boolean dumpOnError; |
|
88 |
||
89 |
/** Print multiple errors for same source locations. |
|
90 |
*/ |
|
91 |
public boolean multipleErrors; |
|
92 |
||
93 |
/** |
|
94 |
* Diagnostic listener, if provided through programmatic |
|
95 |
* interface to javac (JSR 199). |
|
96 |
*/ |
|
97 |
protected DiagnosticListener<? super JavaFileObject> diagListener; |
|
867 | 98 |
|
10 | 99 |
/** |
2085
4792e12a8ca2
6769027: Source line should be displayed immediately after the first diagnostic line
mcimadamore
parents:
1866
diff
changeset
|
100 |
* Formatter for diagnostics. |
10 | 101 |
*/ |
942 | 102 |
private DiagnosticFormatter<JCDiagnostic> diagFormatter; |
10 | 103 |
|
1471
57506cdfb7b4
6406133: JCDiagnostic.getMessage ignores locale argument
mcimadamore
parents:
1109
diff
changeset
|
104 |
/** |
2085
4792e12a8ca2
6769027: Source line should be displayed immediately after the first diagnostic line
mcimadamore
parents:
1866
diff
changeset
|
105 |
* Keys for expected diagnostics. |
1866 | 106 |
*/ |
107 |
public Set<String> expectDiagKeys; |
|
108 |
||
109 |
/** |
|
2085
4792e12a8ca2
6769027: Source line should be displayed immediately after the first diagnostic line
mcimadamore
parents:
1866
diff
changeset
|
110 |
* JavacMessages object used for localization. |
1471
57506cdfb7b4
6406133: JCDiagnostic.getMessage ignores locale argument
mcimadamore
parents:
1109
diff
changeset
|
111 |
*/ |
57506cdfb7b4
6406133: JCDiagnostic.getMessage ignores locale argument
mcimadamore
parents:
1109
diff
changeset
|
112 |
private JavacMessages messages; |
57506cdfb7b4
6406133: JCDiagnostic.getMessage ignores locale argument
mcimadamore
parents:
1109
diff
changeset
|
113 |
|
10 | 114 |
/** Construct a log with given I/O redirections. |
115 |
*/ |
|
116 |
@Deprecated |
|
117 |
protected Log(Context context, PrintWriter errWriter, PrintWriter warnWriter, PrintWriter noticeWriter) { |
|
867 | 118 |
super(JCDiagnostic.Factory.instance(context)); |
10 | 119 |
context.put(logKey, this); |
120 |
this.errWriter = errWriter; |
|
121 |
this.warnWriter = warnWriter; |
|
122 |
this.noticeWriter = noticeWriter; |
|
123 |
||
124 |
Options options = Options.instance(context); |
|
125 |
this.dumpOnError = options.get("-doe") != null; |
|
126 |
this.promptOnError = options.get("-prompt") != null; |
|
127 |
this.emitWarnings = options.get("-Xlint:none") == null; |
|
3660 | 128 |
this.suppressNotes = options.get("suppressNotes") != null; |
10 | 129 |
this.MaxErrors = getIntOption(options, "-Xmaxerrs", 100); |
130 |
this.MaxWarnings = getIntOption(options, "-Xmaxwarns", 100); |
|
131 |
||
942 | 132 |
boolean rawDiagnostics = options.get("rawDiagnostics") != null; |
1471
57506cdfb7b4
6406133: JCDiagnostic.getMessage ignores locale argument
mcimadamore
parents:
1109
diff
changeset
|
133 |
messages = JavacMessages.instance(context); |
1472
1e09e143438c
6731573: diagnostic output should optionally include source line
mcimadamore
parents:
1471
diff
changeset
|
134 |
this.diagFormatter = rawDiagnostics ? new RawDiagnosticFormatter(options) : |
1471
57506cdfb7b4
6406133: JCDiagnostic.getMessage ignores locale argument
mcimadamore
parents:
1109
diff
changeset
|
135 |
new BasicDiagnosticFormatter(options, messages); |
10 | 136 |
@SuppressWarnings("unchecked") // FIXME |
1866 | 137 |
DiagnosticListener<? super JavaFileObject> dl = |
10 | 138 |
context.get(DiagnosticListener.class); |
1866 | 139 |
this.diagListener = dl; |
140 |
||
141 |
String ek = options.get("expectKeys"); |
|
142 |
if (ek != null) |
|
143 |
expectDiagKeys = new HashSet<String>(Arrays.asList(ek.split(", *"))); |
|
10 | 144 |
} |
145 |
// where |
|
146 |
private int getIntOption(Options options, String optionName, int defaultValue) { |
|
147 |
String s = options.get(optionName); |
|
148 |
try { |
|
149 |
if (s != null) return Integer.parseInt(s); |
|
150 |
} catch (NumberFormatException e) { |
|
151 |
// silently ignore ill-formed numbers |
|
152 |
} |
|
153 |
return defaultValue; |
|
154 |
} |
|
155 |
||
156 |
/** The default writer for diagnostics |
|
157 |
*/ |
|
158 |
static final PrintWriter defaultWriter(Context context) { |
|
159 |
PrintWriter result = context.get(outKey); |
|
160 |
if (result == null) |
|
161 |
context.put(outKey, result = new PrintWriter(System.err)); |
|
162 |
return result; |
|
163 |
} |
|
164 |
||
165 |
/** Construct a log with default settings. |
|
166 |
*/ |
|
167 |
protected Log(Context context) { |
|
168 |
this(context, defaultWriter(context)); |
|
169 |
} |
|
170 |
||
171 |
/** Construct a log with all output redirected. |
|
172 |
*/ |
|
173 |
protected Log(Context context, PrintWriter defaultWriter) { |
|
174 |
this(context, defaultWriter, defaultWriter, defaultWriter); |
|
175 |
} |
|
176 |
||
177 |
/** Get the Log instance for this context. */ |
|
178 |
public static Log instance(Context context) { |
|
179 |
Log instance = context.get(logKey); |
|
180 |
if (instance == null) |
|
181 |
instance = new Log(context); |
|
182 |
return instance; |
|
183 |
} |
|
184 |
||
185 |
/** The number of errors encountered so far. |
|
186 |
*/ |
|
187 |
public int nerrors = 0; |
|
188 |
||
189 |
/** The number of warnings encountered so far. |
|
190 |
*/ |
|
191 |
public int nwarnings = 0; |
|
192 |
||
193 |
/** A set of all errors generated so far. This is used to avoid printing an |
|
194 |
* error message more than once. For each error, a pair consisting of the |
|
195 |
* source file name and source code position of the error is added to the set. |
|
196 |
*/ |
|
197 |
private Set<Pair<JavaFileObject, Integer>> recorded = new HashSet<Pair<JavaFileObject,Integer>>(); |
|
198 |
||
199 |
public boolean hasDiagnosticListener() { |
|
200 |
return diagListener != null; |
|
201 |
} |
|
202 |
||
203 |
public void setEndPosTable(JavaFileObject name, Map<JCTree, Integer> table) { |
|
867 | 204 |
name.getClass(); // null check |
205 |
getSource(name).setEndPosTable(table); |
|
10 | 206 |
} |
207 |
||
1591
e5a618442f5f
6768932: Add support for multiline diagnostics
mcimadamore
parents:
1472
diff
changeset
|
208 |
/** Return current sourcefile. |
10 | 209 |
*/ |
1591
e5a618442f5f
6768932: Add support for multiline diagnostics
mcimadamore
parents:
1472
diff
changeset
|
210 |
public JavaFileObject currentSourceFile() { |
10 | 211 |
return source == null ? null : source.getFile(); |
212 |
} |
|
213 |
||
2085
4792e12a8ca2
6769027: Source line should be displayed immediately after the first diagnostic line
mcimadamore
parents:
1866
diff
changeset
|
214 |
/** Get the current diagnostic formatter. |
4792e12a8ca2
6769027: Source line should be displayed immediately after the first diagnostic line
mcimadamore
parents:
1866
diff
changeset
|
215 |
*/ |
4792e12a8ca2
6769027: Source line should be displayed immediately after the first diagnostic line
mcimadamore
parents:
1866
diff
changeset
|
216 |
public DiagnosticFormatter<JCDiagnostic> getDiagnosticFormatter() { |
4792e12a8ca2
6769027: Source line should be displayed immediately after the first diagnostic line
mcimadamore
parents:
1866
diff
changeset
|
217 |
return diagFormatter; |
4792e12a8ca2
6769027: Source line should be displayed immediately after the first diagnostic line
mcimadamore
parents:
1866
diff
changeset
|
218 |
} |
4792e12a8ca2
6769027: Source line should be displayed immediately after the first diagnostic line
mcimadamore
parents:
1866
diff
changeset
|
219 |
|
4792e12a8ca2
6769027: Source line should be displayed immediately after the first diagnostic line
mcimadamore
parents:
1866
diff
changeset
|
220 |
/** Set the current diagnostic formatter. |
4792e12a8ca2
6769027: Source line should be displayed immediately after the first diagnostic line
mcimadamore
parents:
1866
diff
changeset
|
221 |
*/ |
4792e12a8ca2
6769027: Source line should be displayed immediately after the first diagnostic line
mcimadamore
parents:
1866
diff
changeset
|
222 |
public void setDiagnosticFormatter(DiagnosticFormatter<JCDiagnostic> diagFormatter) { |
4792e12a8ca2
6769027: Source line should be displayed immediately after the first diagnostic line
mcimadamore
parents:
1866
diff
changeset
|
223 |
this.diagFormatter = diagFormatter; |
4792e12a8ca2
6769027: Source line should be displayed immediately after the first diagnostic line
mcimadamore
parents:
1866
diff
changeset
|
224 |
} |
4792e12a8ca2
6769027: Source line should be displayed immediately after the first diagnostic line
mcimadamore
parents:
1866
diff
changeset
|
225 |
|
10 | 226 |
/** Flush the logs |
227 |
*/ |
|
228 |
public void flush() { |
|
229 |
errWriter.flush(); |
|
230 |
warnWriter.flush(); |
|
231 |
noticeWriter.flush(); |
|
232 |
} |
|
233 |
||
234 |
/** Returns true if an error needs to be reported for a given |
|
235 |
* source name and pos. |
|
236 |
*/ |
|
237 |
protected boolean shouldReport(JavaFileObject file, int pos) { |
|
238 |
if (multipleErrors || file == null) |
|
239 |
return true; |
|
240 |
||
241 |
Pair<JavaFileObject,Integer> coords = new Pair<JavaFileObject,Integer>(file, pos); |
|
242 |
boolean shouldReport = !recorded.contains(coords); |
|
243 |
if (shouldReport) |
|
244 |
recorded.add(coords); |
|
245 |
return shouldReport; |
|
246 |
} |
|
247 |
||
248 |
/** Prompt user after an error. |
|
249 |
*/ |
|
250 |
public void prompt() { |
|
251 |
if (promptOnError) { |
|
252 |
System.err.println(getLocalizedString("resume.abort")); |
|
253 |
char ch; |
|
254 |
try { |
|
255 |
while (true) { |
|
256 |
switch (System.in.read()) { |
|
257 |
case 'a': case 'A': |
|
258 |
System.exit(-1); |
|
259 |
return; |
|
260 |
case 'r': case 'R': |
|
261 |
return; |
|
262 |
case 'x': case 'X': |
|
263 |
throw new AssertionError("user abort"); |
|
264 |
default: |
|
265 |
} |
|
266 |
} |
|
267 |
} catch (IOException e) {} |
|
268 |
} |
|
269 |
} |
|
270 |
||
271 |
/** Print the faulty source code line and point to the error. |
|
272 |
* @param pos Buffer index of the error position, must be on current line |
|
273 |
*/ |
|
274 |
private void printErrLine(int pos, PrintWriter writer) { |
|
867 | 275 |
String line = (source == null ? null : source.getLine(pos)); |
276 |
if (line == null) |
|
10 | 277 |
return; |
1109
853d8c191eac
6733837: Recent work on javac diagnostic affected javac output
mcimadamore
parents:
942
diff
changeset
|
278 |
int col = source.getColumnNumber(pos, false); |
10 | 279 |
|
867 | 280 |
printLines(writer, line); |
281 |
for (int i = 0; i < col - 1; i++) { |
|
282 |
writer.print((line.charAt(i) == '\t') ? "\t" : " "); |
|
10 | 283 |
} |
284 |
writer.println("^"); |
|
285 |
writer.flush(); |
|
286 |
} |
|
287 |
||
288 |
/** Print the text of a message, translating newlines appropriately |
|
289 |
* for the platform. |
|
290 |
*/ |
|
291 |
public static void printLines(PrintWriter writer, String msg) { |
|
292 |
int nl; |
|
293 |
while ((nl = msg.indexOf('\n')) != -1) { |
|
294 |
writer.println(msg.substring(0, nl)); |
|
295 |
msg = msg.substring(nl+1); |
|
296 |
} |
|
297 |
if (msg.length() != 0) writer.println(msg); |
|
298 |
} |
|
299 |
||
867 | 300 |
protected void directError(String key, Object... args) { |
301 |
printLines(errWriter, getLocalizedString(key, args)); |
|
302 |
errWriter.flush(); |
|
10 | 303 |
} |
304 |
||
305 |
/** Report a warning that cannot be suppressed. |
|
306 |
* @param pos The source position at which to report the warning. |
|
307 |
* @param key The key for the localized warning message. |
|
308 |
* @param args Fields of the warning message. |
|
309 |
*/ |
|
310 |
public void strictWarning(DiagnosticPosition pos, String key, Object ... args) { |
|
311 |
writeDiagnostic(diags.warning(source, pos, key, args)); |
|
312 |
nwarnings++; |
|
313 |
} |
|
314 |
||
315 |
/** |
|
316 |
* Common diagnostic handling. |
|
317 |
* The diagnostic is counted, and depending on the options and how many diagnostics have been |
|
318 |
* reported so far, the diagnostic may be handed off to writeDiagnostic. |
|
319 |
*/ |
|
320 |
public void report(JCDiagnostic diagnostic) { |
|
1866 | 321 |
if (expectDiagKeys != null) |
322 |
expectDiagKeys.remove(diagnostic.getCode()); |
|
323 |
||
10 | 324 |
switch (diagnostic.getType()) { |
325 |
case FRAGMENT: |
|
326 |
throw new IllegalArgumentException(); |
|
327 |
||
328 |
case NOTE: |
|
329 |
// Print out notes only when we are permitted to report warnings |
|
330 |
// Notes are only generated at the end of a compilation, so should be small |
|
331 |
// in number. |
|
3660 | 332 |
if ((emitWarnings || diagnostic.isMandatory()) && !suppressNotes) { |
10 | 333 |
writeDiagnostic(diagnostic); |
334 |
} |
|
335 |
break; |
|
336 |
||
337 |
case WARNING: |
|
338 |
if (emitWarnings || diagnostic.isMandatory()) { |
|
339 |
if (nwarnings < MaxWarnings) { |
|
340 |
writeDiagnostic(diagnostic); |
|
341 |
nwarnings++; |
|
342 |
} |
|
343 |
} |
|
344 |
break; |
|
345 |
||
346 |
case ERROR: |
|
347 |
if (nerrors < MaxErrors |
|
348 |
&& shouldReport(diagnostic.getSource(), diagnostic.getIntPosition())) { |
|
349 |
writeDiagnostic(diagnostic); |
|
350 |
nerrors++; |
|
351 |
} |
|
352 |
break; |
|
353 |
} |
|
354 |
} |
|
355 |
||
356 |
/** |
|
357 |
* Write out a diagnostic. |
|
358 |
*/ |
|
359 |
protected void writeDiagnostic(JCDiagnostic diag) { |
|
360 |
if (diagListener != null) { |
|
361 |
try { |
|
362 |
diagListener.report(diag); |
|
363 |
return; |
|
364 |
} |
|
365 |
catch (Throwable t) { |
|
366 |
throw new ClientCodeException(t); |
|
367 |
} |
|
368 |
} |
|
369 |
||
370 |
PrintWriter writer = getWriterForDiagnosticType(diag.getType()); |
|
371 |
||
1471
57506cdfb7b4
6406133: JCDiagnostic.getMessage ignores locale argument
mcimadamore
parents:
1109
diff
changeset
|
372 |
printLines(writer, diagFormatter.format(diag, messages.getCurrentLocale())); |
10 | 373 |
|
374 |
if (promptOnError) { |
|
375 |
switch (diag.getType()) { |
|
376 |
case ERROR: |
|
377 |
case WARNING: |
|
378 |
prompt(); |
|
379 |
} |
|
380 |
} |
|
381 |
||
382 |
if (dumpOnError) |
|
383 |
new RuntimeException().printStackTrace(writer); |
|
384 |
||
385 |
writer.flush(); |
|
386 |
} |
|
387 |
||
388 |
@Deprecated |
|
389 |
protected PrintWriter getWriterForDiagnosticType(DiagnosticType dt) { |
|
390 |
switch (dt) { |
|
391 |
case FRAGMENT: |
|
392 |
throw new IllegalArgumentException(); |
|
393 |
||
394 |
case NOTE: |
|
395 |
return noticeWriter; |
|
396 |
||
397 |
case WARNING: |
|
398 |
return warnWriter; |
|
399 |
||
400 |
case ERROR: |
|
401 |
return errWriter; |
|
402 |
||
403 |
default: |
|
404 |
throw new Error(); |
|
405 |
} |
|
406 |
} |
|
407 |
||
408 |
/** Find a localized string in the resource bundle. |
|
409 |
* @param key The key for the localized string. |
|
410 |
* @param args Fields to substitute into the string. |
|
411 |
*/ |
|
412 |
public static String getLocalizedString(String key, Object ... args) { |
|
1471
57506cdfb7b4
6406133: JCDiagnostic.getMessage ignores locale argument
mcimadamore
parents:
1109
diff
changeset
|
413 |
return JavacMessages.getDefaultLocalizedString("compiler.misc." + key, args); |
10 | 414 |
} |
415 |
||
416 |
/*************************************************************************** |
|
417 |
* raw error messages without internationalization; used for experimentation |
|
418 |
* and quick prototyping |
|
419 |
***************************************************************************/ |
|
420 |
||
867 | 421 |
/** print an error or warning message: |
422 |
*/ |
|
10 | 423 |
private void printRawError(int pos, String msg) { |
867 | 424 |
if (source == null || pos == Position.NOPOS) { |
10 | 425 |
printLines(errWriter, "error: " + msg); |
426 |
} else { |
|
867 | 427 |
int line = source.getLineNumber(pos); |
1591
e5a618442f5f
6768932: Add support for multiline diagnostics
mcimadamore
parents:
1472
diff
changeset
|
428 |
JavaFileObject file = source.getFile(); |
10 | 429 |
if (file != null) |
430 |
printLines(errWriter, |
|
431 |
JavacFileManager.getJavacFileName(file) + ":" + |
|
432 |
line + ": " + msg); |
|
433 |
printErrLine(pos, errWriter); |
|
434 |
} |
|
435 |
errWriter.flush(); |
|
436 |
} |
|
437 |
||
867 | 438 |
/** report an error: |
439 |
*/ |
|
10 | 440 |
public void rawError(int pos, String msg) { |
1591
e5a618442f5f
6768932: Add support for multiline diagnostics
mcimadamore
parents:
1472
diff
changeset
|
441 |
if (nerrors < MaxErrors && shouldReport(currentSourceFile(), pos)) { |
10 | 442 |
printRawError(pos, msg); |
443 |
prompt(); |
|
444 |
nerrors++; |
|
445 |
} |
|
446 |
errWriter.flush(); |
|
447 |
} |
|
448 |
||
867 | 449 |
/** report a warning: |
450 |
*/ |
|
10 | 451 |
public void rawWarning(int pos, String msg) { |
452 |
if (nwarnings < MaxWarnings && emitWarnings) { |
|
453 |
printRawError(pos, "warning: " + msg); |
|
454 |
} |
|
455 |
prompt(); |
|
456 |
nwarnings++; |
|
457 |
errWriter.flush(); |
|
458 |
} |
|
459 |
||
460 |
public static String format(String fmt, Object... args) { |
|
461 |
return String.format((java.util.Locale)null, fmt, args); |
|
462 |
} |
|
463 |
||
464 |
} |