Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8095210

[Javadoc] ScheduledService example uses non-existent constructor with Duration argument

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P5 P5
    • 8u40
    • 8u25
    • javafx
    • JDK 8u25, Win 7 Pro SP1, 64 Bit

      The JavaDocs of ScheduledService contains a code example which is using a constructor of the form "ScheduledService(Duration)".

      Actually ScheduledService does not provide such a constructor. It is not possible to provide a Duration to the ScheduledService construtor. Instead the duration has set using ScheduledService.setDelay(Duration).

      The JavaDocs should get fixed ASAP to not further confuse people. :-)

            kcr Kevin Rushforth
            mkarg Markus Karg
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported: