< prev index next >

src/java.base/share/classes/java/lang/BaseVirtualThread.java

Print this page
@@ -61,7 +61,15 @@
  
      /**
       * Makes available the parking permit to the given this virtual thread.
       */
      abstract void unpark();
+ 
+     /**
+      * Makes available the parking permit to the given this virtual thread. If the
+      * thread is parked then there is no guarantee that it will continue execution.
+      */
+     void lazyUnpark() {
+         unpark();
+     }
  }
  
< prev index next >