Modernize examples in StringTokenizer and {Date,Number}Format

XMLWordPrintable

    • Type: Bug
    • Resolution: Fixed
    • Priority: P5
    • 22
    • Affects Version/s: 22
    • Component/s: core-libs
    • b16

      This could use the enhanced for-statement introduced in JDK 1.5:

       * The following example illustrates how the {@code String.split}
       * method can be used to break up a string into its basic tokens:
       * <blockquote><pre>
       * String[] result = "this is a test".split("\\s");
       * for (int x=0; x&lt;result.length; x++)
       * System.out.println(result[x]);
       * </pre></blockquote>

            Assignee:
            Pavel Rappo
            Reporter:
            Pavel Rappo
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: