@Override protected int tryAcquireShared(int acquires){
  Thread queuedThread=getFirstQueuedThread();
  if (queuedThread != null && queuedThread != Thread.currentThread())   return -1;
  if (acquires == 0)   return isClosed() ? 1 : -1;
  setState(1);
  return 1;
}

@ Override protected int tryAcquireShared ( int acquires ) { Thread queuedThread = getFirstQueuedThread ( ) ; if ( queuedThread != null && queuedThread != Thread . currentThread ( ) ) return - 1 ; if ( acquires == 0 ) return isClosed ( ) ? 1 : - 1 ; setState ( 1 ) ; return 1 ; }
opens the circuit if not a test .
