src/share/classes/com/sun/tools/doclint/DocLint.java

changeset 1506
4a3cfc970c6f
parent 1458
ef537bcc825a
child 1668
991f11e13598
     1.1 --- a/src/share/classes/com/sun/tools/doclint/DocLint.java	Fri Jan 18 15:38:14 2013 +0000
     1.2 +++ b/src/share/classes/com/sun/tools/doclint/DocLint.java	Mon Jan 21 10:00:46 2013 -0800
     1.3 @@ -1,5 +1,5 @@
     1.4  /*
     1.5 - * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved.
     1.6 + * Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved.
     1.7   * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     1.8   *
     1.9   * This code is free software; you can redistribute it and/or modify it
    1.10 @@ -122,7 +122,7 @@
    1.11  
    1.12          if (javacFiles.isEmpty()) {
    1.13              if (!needHelp)
    1.14 -                System.out.println("no files given");
    1.15 +                out.println("no files given");
    1.16          }
    1.17  
    1.18          JavacTool tool = JavacTool.create();
    1.19 @@ -179,11 +179,11 @@
    1.20                  }
    1.21              } else if (arg.equals(STATS)) {
    1.22                  env.messages.setStatsEnabled(true);
    1.23 -            } else if (arg.matches("-bootclasspath") && i + 1 < args.length) {
    1.24 +            } else if (arg.equals("-bootclasspath") && i + 1 < args.length) {
    1.25                  javacBootClassPath = splitPath(args[++i]);
    1.26 -            } else if (arg.matches("-classpath") && i + 1 < args.length) {
    1.27 +            } else if (arg.equals("-classpath") && i + 1 < args.length) {
    1.28                  javacClassPath = splitPath(args[++i]);
    1.29 -            } else if (arg.matches("-sourcepath") && i + 1 < args.length) {
    1.30 +            } else if (arg.equals("-sourcepath") && i + 1 < args.length) {
    1.31                  javacSourcePath = splitPath(args[++i]);
    1.32              } else if (arg.equals(XMSGS_OPTION)) {
    1.33                  env.messages.setOptions(null);
    1.34 @@ -234,6 +234,8 @@
    1.35          out.println("    equivalent to -Xmsgs:all/protected, meaning that");
    1.36          out.println("    all messages are reported for protected and public");
    1.37          out.println("    declarations only. ");
    1.38 +        out.println("  -stats");
    1.39 +        out.println("    Report statistics on the reported issues.");
    1.40          out.println("  -h -help --help -usage -?");
    1.41          out.println("    Show this message.");
    1.42          out.println("");
    1.43 @@ -247,7 +249,7 @@
    1.44  
    1.45      List<File> splitPath(String path) {
    1.46          List<File> files = new ArrayList<File>();
    1.47 -        for (String f: path.split(File.separator)) {
    1.48 +        for (String f: path.split(File.pathSeparator)) {
    1.49              if (f.length() > 0)
    1.50                  files.add(new File(f));
    1.51          }

mercurial