diff options
author | Reinier Zwitserloot <reinier@zwitserloot.com> | 2012-08-13 00:11:02 +0200 |
---|---|---|
committer | Reinier Zwitserloot <reinier@zwitserloot.com> | 2012-08-13 00:11:02 +0200 |
commit | 8850798a04e7f44925ed16b3450623b02f5b6295 (patch) | |
tree | 7e40b1f95e1ad082ee135bf3ae9b1de4e946d2d4 /usage_examples/experimental/WitherExample_pre.jpage | |
parent | 42f5a55d69850603d951a65929f48a3b462b54ea (diff) | |
download | lombok-8850798a04e7f44925ed16b3450623b02f5b6295.tar.gz lombok-8850798a04e7f44925ed16b3450623b02f5b6295.tar.bz2 lombok-8850798a04e7f44925ed16b3450623b02f5b6295.zip |
Documentation for @Value, @FieldDefaults, @Wither
Diffstat (limited to 'usage_examples/experimental/WitherExample_pre.jpage')
-rw-r--r-- | usage_examples/experimental/WitherExample_pre.jpage | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/usage_examples/experimental/WitherExample_pre.jpage b/usage_examples/experimental/WitherExample_pre.jpage new file mode 100644 index 00000000..5db799fc --- /dev/null +++ b/usage_examples/experimental/WitherExample_pre.jpage @@ -0,0 +1,14 @@ +import lombok.AccessLevel; +import lombok.NonNull; +import lombok.experimental.Wither; + +public class WitherExample { + @Wither private final int age; + @Wither(AccessLevel.PROTECTED) @NonNull private final String name; + + public WitherExample(String name, int age) { + if (name == null) throw new NullPointerException(); + this.name = name; + this.age = age; + } +} |