boolean function ( final String arg0 ) { Lock loc0 = readLock ( ) ; try { return current . equals ( arg0 ) ; } finally { loc0 . unlock ( ) ; } }
check if the current state is given state . code executed after may not have the same state , to execute and ensure state is allowed use #guard instead . concode_field_sep String current concode_elem_sep Logger log concode_elem_sep String initial concode_elem_sep String failure concode_elem_sep String[] allowed concode_elem_sep Logger logger concode_elem_sep ReadWriteLock lock concode_elem_sep String to concode_field_sep Lock writeLock concode_elem_sep void ensure concode_elem_sep Builder initial concode_elem_sep Lock readLock concode_elem_sep Guard guard concode_elem_sep Builder logger concode_elem_sep V run concode_elem_sep V run concode_elem_sep Lock tryLock concode_elem_sep Transition transition concode_elem_sep void _ensure concode_elem_sep Builder failure concode_elem_sep Builder lock concode_elem_sep StateGuard create concode_elem_sep String toString concode_elem_sep String toString concode_elem_sep TransitionImpl from concode_elem_sep String getCurrent