src/jdk.jfr/share/classes/jdk/jfr/consumer/RecordingStream.java
branchJEP-349-branch
changeset 58357 fe78b5a87287
parent 58200 2d147d680311
child 58369 d55d1bd947c2
--- a/src/jdk.jfr/share/classes/jdk/jfr/consumer/RecordingStream.java	Wed Sep 25 22:40:41 2019 +0200
+++ b/src/jdk.jfr/share/classes/jdk/jfr/consumer/RecordingStream.java	Thu Sep 26 15:13:04 2019 +0200
@@ -54,7 +54,7 @@
  * <pre>
  * <code>
  * Configuration c = Configuration.getConfiguration("default");
- * try (RecordingStream rs = new RecordingStream(c)) {
+ * try (var rs = new RecordingStream(c)) {
  *     rs.onEvent("jdk.GarbageCollection", System.out::println);
  *     rs.onEvent("jdk.CPULoad", System.out::println);
  *     rs.onEvent("jdk.JVMInformation", System.out::println);
@@ -104,7 +104,7 @@
      * <pre>
      * <code>
      * var c = Configuration.getConfiguration("default");
-     * try (RecordingStream rs = new RecordingStream(c)) {
+     * try (var rs = new RecordingStream(c)) {
      *   rs.onEvent(System.out::println);
      *   rs.start();
      * }
@@ -156,7 +156,7 @@
      * <code>
      *     Configuration defaultConfiguration = Configuration.getConfiguration("default");
      *     Configuration profileConfiguration = Configuration.getConfiguration("profile");
-     *     try (RecordingStream rs = new RecordingStream(defaultConfiguration) {
+     *     try (var rs = new RecordingStream(defaultConfiguration) {
      *        rs.onEvent(System.out::println);
      *        rs.startAsync();
      *        Thread.sleep(20_000);
@@ -234,7 +234,7 @@
      * @param maxAge the length of time that data is kept, or {@code null} if
      *        infinite
      *
-     * @throws IllegalArgumentException if <code>maxAge</code> is negative
+     * @throws IllegalArgumentException if {@code maxAge} is negative
      *
      * @throws IllegalStateException if the recording is in the {@code CLOSED}
      *         state
@@ -256,7 +256,7 @@
      *
      * @param maxSize the amount of data to retain, {@code 0} if infinite
      *
-     * @throws IllegalArgumentException if <code>maxSize</code> is negative
+     * @throws IllegalArgumentException if {@code maxSize} is negative
      *
      * @throws IllegalStateException if the recording is in {@code CLOSED} state
      */
@@ -270,7 +270,7 @@
      * @param interval the interval at which events are made available to the
      *        stream, no {@code null}
      *
-     * @throws IllegalArgumentException if <code>interval</code> is negative
+     * @throws IllegalArgumentException if {@code interval} is negative
      *
      * @throws IllegalStateException if the stream is closed
      */