Java_exception
if the thread is interruptedexchange_time e x t u
is similar to exchange e x
, except that the
current thread will at most wait for t
(time value whose unit is
u
); see
exchange(...).Java_exception
if the thread is interruptedJava_exception
if time has elapsed with no exchangewrap obj
wraps the reference obj
into an option type:Some x
if obj
is not null
;None
if obj
is null
.unwrap obj
unwraps the option obj
into a bare reference:Some x
is mapped to x
;None
is mapped to null
.