aboutsummaryrefslogtreecommitdiff
path: root/website/features
diff options
context:
space:
mode:
authorReinier Zwitserloot <reinier@zwitserloot.com>2015-08-16 02:42:43 +0200
committerReinier Zwitserloot <reinier@zwitserloot.com>2015-08-16 02:42:43 +0200
commit62877ecdb2e5e13a2eb7b67db5292cd13b20cc39 (patch)
treef17bcf43f047845b4fa138929f227129a62819ee /website/features
parent059d2b5304514d0ae24dd3444826d2afc315c60f (diff)
parentfd1d18a29957fc1999b7dd5725641662ad3bd887 (diff)
downloadlombok-62877ecdb2e5e13a2eb7b67db5292cd13b20cc39.tar.gz
lombok-62877ecdb2e5e13a2eb7b67db5292cd13b20cc39.tar.bz2
lombok-62877ecdb2e5e13a2eb7b67db5292cd13b20cc39.zip
Merge branch 'force'
Conflicts: doc/changelog.markdown src/core/lombok/eclipse/handlers/HandleBuilder.java
Diffstat (limited to 'website/features')
-rw-r--r--website/features/Constructor.html3
1 files changed, 1 insertions, 2 deletions
diff --git a/website/features/Constructor.html b/website/features/Constructor.html
index cbb76fcf..d7168372 100644
--- a/website/features/Constructor.html
+++ b/website/features/Constructor.html
@@ -17,8 +17,7 @@
<p>
This set of 3 annotations generate a constructor that will accept 1 parameter for certain fields, and simply assigns this parameter to the field.
</p><p>
- <code>@NoArgsConstructor</code> will generate a constructor with no parameters. If this is not possible (because of final fields), a compiler error will result instead.
- For fields with constraints, such as <code>@NonNull</code> fields, <em>no</em> check or assignment is generated, so be aware that these constraints may then not be
+ <code>@NoArgsConstructor</code> will generate a constructor with no parameters. If this is not possible (because of final fields), a compiler error will result instead, unless <code>@NoArgsConstructor(force = true)</code> is used, then all final fields are initialized with 0 / false / null. For fields with constraints, such as <code>@NonNull</code> fields, <em>no</em> check or assignment is generated, so be aware that these constraints may then not be
fulfilled until those fields are properly initialized later. Certain java constructs, such as hibernate and the Service Provider Interface require a no-args constructor.
This annotation is useful primarily in combination with either <code>@Data</code> or one of the other constructor generating annotations.
</p><p>