diff options
author | Reinier Zwitserloot <reinier@zwitserloot.com> | 2015-10-06 00:25:32 +0200 |
---|---|---|
committer | Reinier Zwitserloot <reinier@zwitserloot.com> | 2015-10-06 00:25:32 +0200 |
commit | 9d8c4e4099bef9b7854cc5d77bc996c3b3bf0e41 (patch) | |
tree | 6ca48925c989d3f314fbeef08931a1940b5c03cf /website | |
parent | b4d69f5cb8b093718bb7ffb539e5875df52ca48e (diff) | |
download | lombok-9d8c4e4099bef9b7854cc5d77bc996c3b3bf0e41.tar.gz lombok-9d8c4e4099bef9b7854cc5d77bc996c3b3bf0e41.tar.bz2 lombok-9d8c4e4099bef9b7854cc5d77bc996c3b3bf0e41.zip |
New feature: FieldDefaults can now be configured to apply to _every_ file, regardless of annotations.
Diffstat (limited to 'website')
-rw-r--r-- | website/features/configuration.html | 9 | ||||
-rw-r--r-- | website/features/experimental/FieldDefaults.html | 4 |
2 files changed, 13 insertions, 0 deletions
diff --git a/website/features/configuration.html b/website/features/configuration.html index 7e79a9c0..21864409 100644 --- a/website/features/configuration.html +++ b/website/features/configuration.html @@ -85,6 +85,15 @@ <code>lombok.extern.findbugs.addSuppressFBWarnings = true</code> </div> </div> + <div class="overview" style="clear: left;"> + <h3>Config keys that can even affect source files with 0 lombok annotations</h3> + <p> + <div class="snippet example"> + <code>lombok.fieldDefaults.defaultPrivate = true</code><br /> + <code>lombok.fieldDefaults.defaultFinal = true</code> + </div> + Turning either of these options on means lombok will make <em>every</em> field in <em>every</em> source file final and/or private unless it has an explicit access modifier or annotation to suppress this. <a href="experimental/FieldDefaults.html">See the <code>@FieldDefaults</code> documentation for more</a>. + </div> <div style="clear: left;"></div> <div class="footer"> <a href="index.html">Back to features</a> | <a href="Log.html">Previous feature (@Log)</a> | <span class="disabled">Next feature</span><br /> diff --git a/website/features/experimental/FieldDefaults.html b/website/features/experimental/FieldDefaults.html index 5ad30952..026f23fc 100644 --- a/website/features/experimental/FieldDefaults.html +++ b/website/features/experimental/FieldDefaults.html @@ -61,6 +61,10 @@ <dl> <dt><code>lombok.fieldDefaults.flagUsage</code> = [<code>warning</code> | <code>error</code>] (default: not set)</dt> <dd>Lombok will flag any usage of <code>@FieldDefaults</code> as a warning or error if configured.</dd> + <dt><code>lombok.fieldDefaults.defaultPrivate</code> = [<code>true</code> | <code>false</code>] (default: false)</dt> + <dd>(Since 1.16.8) If set to <code>true</code>, <em>every</em> field in <em>every</em> class or enum anywhere in the sources being compiled will be marked as <code>private</code> unless it has an explicit access modifier or the <code>@PackagePrivate</code> annotation, or an explicit <code>@FieldDefaults</code> annotation is present to override this config key.</dd> + <dt><code>lombok.fieldDefaults.defaultFinal</code> = [<code>true</code> | <code>false</code>] (default: false)</dt> + <dd>(Since 1.16.8) If set to <code>true</code>, <em>every</em> field in <em>every</em> class or enum anywhere in the sources being compiled will be marked as <code>final</code> unless it has the <code>@NonFinal</code> annotation, or an explicit <code>@FieldDefaults</code> annotation is present to override this config key.</dd> </dl> </div> <div class="overview"> |