< prev index next >

src/java.base/share/classes/jdk/internal/access/JavaLangAccess.java

Print this page

490      * Starts a thread in the given ThreadContainer.
491      */
492     void start(Thread thread, ThreadContainer container);
493 
494     /**
495      * Returns the top of the given thread's stackable scope stack.
496      */
497     StackableScope headStackableScope(Thread thread);
498 
499     /**
500      * Sets the top of the current thread's stackable scope stack.
501      */
502     void setHeadStackableScope(StackableScope scope);
503 
504     /**
505      * Returns the Thread object for the current platform thread. If the
506      * current thread is a virtual thread then this method returns the carrier.
507      */
508     Thread currentCarrierThread();
509 












510     /**
511      * Returns the value of the current carrier thread's copy of a thread-local.
512      */
513     <T> T getCarrierThreadLocal(CarrierThreadLocal<T> local);
514 
515     /**
516      * Sets the value of the current carrier thread's copy of a thread-local.
517      */
518     <T> void setCarrierThreadLocal(CarrierThreadLocal<T> local, T value);
519 
520     /**
521      * Removes the value of the current carrier thread's copy of a thread-local.
522      */
523     void removeCarrierThreadLocal(CarrierThreadLocal<?> local);
524 
525     /**
526      * Returns {@code true} if there is a value in the current carrier thread's copy of
527      * thread-local, even if that values is {@code null}.
528      */
529     boolean isCarrierThreadLocalPresent(CarrierThreadLocal<?> local);

490      * Starts a thread in the given ThreadContainer.
491      */
492     void start(Thread thread, ThreadContainer container);
493 
494     /**
495      * Returns the top of the given thread's stackable scope stack.
496      */
497     StackableScope headStackableScope(Thread thread);
498 
499     /**
500      * Sets the top of the current thread's stackable scope stack.
501      */
502     void setHeadStackableScope(StackableScope scope);
503 
504     /**
505      * Returns the Thread object for the current platform thread. If the
506      * current thread is a virtual thread then this method returns the carrier.
507      */
508     Thread currentCarrierThread();
509 
510     /**
511      * Returns the given virtual thread's carrier or {@code null} if not mounted.
512      * @throws UnsupportedOperationException if the thread is not a virtual thread
513      */
514     Thread getCarrierThread(Thread thread);
515 
516     /**
517      * Returns the given virtual thread's internal state.
518      * @throws UnsupportedOperationException if the thread is not a virtual thread
519      */
520     int getInternalState(Thread thread);
521 
522     /**
523      * Returns the value of the current carrier thread's copy of a thread-local.
524      */
525     <T> T getCarrierThreadLocal(CarrierThreadLocal<T> local);
526 
527     /**
528      * Sets the value of the current carrier thread's copy of a thread-local.
529      */
530     <T> void setCarrierThreadLocal(CarrierThreadLocal<T> local, T value);
531 
532     /**
533      * Removes the value of the current carrier thread's copy of a thread-local.
534      */
535     void removeCarrierThreadLocal(CarrierThreadLocal<?> local);
536 
537     /**
538      * Returns {@code true} if there is a value in the current carrier thread's copy of
539      * thread-local, even if that values is {@code null}.
540      */
541     boolean isCarrierThreadLocalPresent(CarrierThreadLocal<?> local);
< prev index next >