langtools/src/share/classes/com/sun/tools/doclets/formats/html/ConfigurationImpl.java
equal
deleted
inserted
replaced
26 package com.sun.tools.doclets.formats.html; |
26 package com.sun.tools.doclets.formats.html; |
27 |
27 |
28 import java.net.*; |
28 import java.net.*; |
29 import java.util.*; |
29 import java.util.*; |
30 |
30 |
|
31 import javax.tools.JavaFileManager; |
|
32 |
31 import com.sun.javadoc.*; |
33 import com.sun.javadoc.*; |
32 import com.sun.tools.doclets.internal.toolkit.*; |
34 import com.sun.tools.doclets.internal.toolkit.*; |
33 import com.sun.tools.doclets.internal.toolkit.util.*; |
35 import com.sun.tools.doclets.internal.toolkit.util.*; |
|
36 import com.sun.tools.javac.file.JavacFileManager; |
|
37 import com.sun.tools.javac.util.Context; |
34 |
38 |
35 /** |
39 /** |
36 * Configure the output based on the command line options. |
40 * Configure the output based on the command line options. |
37 * <p> |
41 * <p> |
38 * Also determine the length of the command line option. For example, |
42 * Also determine the length of the command line option. For example, |
193 } |
197 } |
194 |
198 |
195 /** |
199 /** |
196 * Return the build date for the doclet. |
200 * Return the build date for the doclet. |
197 */ |
201 */ |
|
202 @Override |
198 public String getDocletSpecificBuildDate() { |
203 public String getDocletSpecificBuildDate() { |
199 return BUILD_DATE; |
204 return BUILD_DATE; |
200 } |
205 } |
201 |
206 |
202 /** |
207 /** |
203 * Depending upon the command line options provided by the user, set |
208 * Depending upon the command line options provided by the user, set |
204 * configure the output generation environment. |
209 * configure the output generation environment. |
205 * |
210 * |
206 * @param options The array of option names and values. |
211 * @param options The array of option names and values. |
207 */ |
212 */ |
|
213 @Override |
208 public void setSpecificDocletOptions(String[][] options) { |
214 public void setSpecificDocletOptions(String[][] options) { |
209 for (int oi = 0; oi < options.length; ++oi) { |
215 for (int oi = 0; oi < options.length; ++oi) { |
210 String[] os = options[oi]; |
216 String[] os = options[oi]; |
211 String opt = os[0].toLowerCase(); |
217 String opt = os[0].toLowerCase(); |
212 if (opt.equals("-footer")) { |
218 if (opt.equals("-footer")) { |
321 } |
327 } |
322 |
328 |
323 /** |
329 /** |
324 * {@inheritDoc} |
330 * {@inheritDoc} |
325 */ |
331 */ |
|
332 @Override |
326 public boolean validOptions(String options[][], |
333 public boolean validOptions(String options[][], |
327 DocErrorReporter reporter) { |
334 DocErrorReporter reporter) { |
328 boolean helpfile = false; |
335 boolean helpfile = false; |
329 boolean nohelp = false; |
336 boolean nohelp = false; |
330 boolean overview = false; |
337 boolean overview = false; |
409 } |
416 } |
410 |
417 |
411 /** |
418 /** |
412 * {@inheritDoc} |
419 * {@inheritDoc} |
413 */ |
420 */ |
|
421 @Override |
414 public MessageRetriever getDocletSpecificMsg() { |
422 public MessageRetriever getDocletSpecificMsg() { |
415 return standardmessage; |
423 return standardmessage; |
416 } |
424 } |
417 |
425 |
418 /** |
426 /** |
478 } |
486 } |
479 |
487 |
480 /** |
488 /** |
481 * {@inheritDoc} |
489 * {@inheritDoc} |
482 */ |
490 */ |
|
491 @Override |
483 public WriterFactory getWriterFactory() { |
492 public WriterFactory getWriterFactory() { |
484 return new WriterFactoryImpl(this); |
493 return new WriterFactoryImpl(this); |
485 } |
494 } |
486 |
495 |
487 /** |
496 /** |
488 * {@inheritDoc} |
497 * {@inheritDoc} |
489 */ |
498 */ |
|
499 @Override |
490 public Comparator<ProgramElementDoc> getMemberComparator() { |
500 public Comparator<ProgramElementDoc> getMemberComparator() { |
491 return null; |
501 return null; |
492 } |
502 } |
493 |
503 |
494 /** |
504 /** |
495 * {@inheritDoc} |
505 * {@inheritDoc} |
496 */ |
506 */ |
|
507 @Override |
497 public Locale getLocale() { |
508 public Locale getLocale() { |
498 if (root instanceof com.sun.tools.javadoc.RootDocImpl) |
509 if (root instanceof com.sun.tools.javadoc.RootDocImpl) |
499 return ((com.sun.tools.javadoc.RootDocImpl)root).getLocale(); |
510 return ((com.sun.tools.javadoc.RootDocImpl)root).getLocale(); |
500 else |
511 else |
501 return Locale.getDefault(); |
512 return Locale.getDefault(); |
502 } |
513 } |
|
514 |
|
515 /** |
|
516 * {@inheritDoc} |
|
517 */ |
|
518 @Override |
|
519 public JavaFileManager getFileManager() { |
|
520 if (root instanceof com.sun.tools.javadoc.RootDocImpl) |
|
521 return ((com.sun.tools.javadoc.RootDocImpl)root).getFileManager(); |
|
522 else |
|
523 return new JavacFileManager(new Context(), false, null); |
|
524 } |
503 } |
525 } |