@ SuppressWarnings ( "GoodTime" ) // should accept a java.time.Duration public boolean enterInterruptibly ( long time , TimeUnit unit ) throws InterruptedException { return lock . tryLock ( time , unit ) ; }
Enters this monitor . Blocks at most the given time and may be interrupted .