diff options
author | Reinier Zwitserloot <r.zwitserloot@projectlombok.org> | 2020-01-18 03:10:07 +0100 |
---|---|---|
committer | Reinier Zwitserloot <r.zwitserloot@projectlombok.org> | 2020-01-28 16:21:39 +0100 |
commit | 91a40b83125808d3684ce07c5cb4a2927d0b979c (patch) | |
tree | ee1105aa16d2db522e26ea16cf11579fee81d893 /test/transform/resource/after-ecj/BuilderWithDeprecated.java | |
parent | 6cc74e42295b6138629c6b32dd56a99ee8c2c646 (diff) | |
download | lombok-91a40b83125808d3684ce07c5cb4a2927d0b979c.tar.gz lombok-91a40b83125808d3684ce07c5cb4a2927d0b979c.tar.bz2 lombok-91a40b83125808d3684ce07c5cb4a2927d0b979c.zip |
[singular][issue #2221] the plural builder method now nullchecks its argument with configurable results.
Diffstat (limited to 'test/transform/resource/after-ecj/BuilderWithDeprecated.java')
-rw-r--r-- | test/transform/resource/after-ecj/BuilderWithDeprecated.java | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/test/transform/resource/after-ecj/BuilderWithDeprecated.java b/test/transform/resource/after-ecj/BuilderWithDeprecated.java index 24d35df1..9dcddc49 100644 --- a/test/transform/resource/after-ecj/BuilderWithDeprecated.java +++ b/test/transform/resource/after-ecj/BuilderWithDeprecated.java @@ -25,6 +25,8 @@ public @Builder class BuilderWithDeprecated { return this; } public @java.lang.Deprecated @java.lang.SuppressWarnings("all") BuilderWithDeprecated.BuilderWithDeprecatedBuilder strings(final java.util.Collection<? extends String> strings) { + if ((strings == null)) + throw new java.lang.NullPointerException("strings cannot be null"); if ((this.strings == null)) this.strings = new java.util.ArrayList<String>(); this.strings.addAll(strings); @@ -42,6 +44,8 @@ public @Builder class BuilderWithDeprecated { return this; } public @java.lang.Deprecated @java.lang.SuppressWarnings("all") BuilderWithDeprecated.BuilderWithDeprecatedBuilder numbers(final java.lang.Iterable<? extends Integer> numbers) { + if ((numbers == null)) + throw new java.lang.NullPointerException("numbers cannot be null"); if ((this.numbers == null)) this.numbers = com.google.common.collect.ImmutableList.builder(); this.numbers.addAll(numbers); |