peichhorn / lombok-pg

Collection of lombok extensions
http://peichhorn.github.com/lombok-pg/
Other
326 stars 44 forks source link

New transient attribute for @BoundPropertySupport #150

Open rguillens opened 8 years ago

rguillens commented 8 years ago

It would be nice to have a way of configuring the change support implementation class. In Java Swing applications, developers may replace PropertyChangeSupport class with the extension SwingPropertyChangeSupport to ensure notifications are sent over AWT Event Dispatch Thread. Instead deprecating the annotation @BountPropertySupport, it shoud allow to configure globally setter's AccessLevel too.

I think the solution would look like this:

@BountPropertySupport(type=SwingPropertyChangeSupport.class, level=AccessLevel.PACKAGE) //Default values are PropertyChangeSupport.class and AccessLevel.PUBLIC
public class Example {
...
}