Groovy Documentation

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

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

class SynchronizedOnGetClassRule
extends AbstractAstVisitorRule

Synchronized on getClass rather than class literal. This instance method synchronizes on this.getClass(). If this class is subclassed, subclasses will synchronize on the class object for the subclass, which isn't likely what was intended.

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