Groovy Documentation

groovy.org.codenarc.rule.concurrency
[Groovy] Class SynchronizedOnReentrantLockRule

java.lang.Object
  org.codenarc.rule.AbstractAstVisitorRule
      groovy.org.codenarc.rule.concurrency.SynchronizedOnReentrantLockRule

class SynchronizedOnReentrantLockRule
extends AbstractAstVisitorRule

Synchronizing on a ReentrantLock field is almost never the intended usage. A ReentrantLock should be obtained using the lock() method and released in a finally block using the unlock() method.

Authors:
'Hamlet D'Arcy'


Property Summary
Class astVisitorClass

String name

int priority

 

Property Detail

astVisitorClass

Class astVisitorClass


name

String name


priority

int priority


 

Groovy Documentation