diff options
author | Bulgakov Alexander <buls@yandex.ru> | 2019-04-26 22:10:34 +0300 |
---|---|---|
committer | Bulgakov Alexander <buls@yandex.ru> | 2019-04-28 22:45:43 +0300 |
commit | ce0a09177e577c0b4f42379c5cc7ce364f26c905 (patch) | |
tree | 497981f2c3668f2afc54ce340972f2fae6859b2a /test/transform/resource/after-delombok/ValDelegateMethodReference.java | |
parent | 150be0a186d880503cb23d056ea4cf229ebc37e5 (diff) | |
download | lombok-ce0a09177e577c0b4f42379c5cc7ce364f26c905.tar.gz lombok-ce0a09177e577c0b4f42379c5cc7ce364f26c905.tar.bz2 lombok-ce0a09177e577c0b4f42379c5cc7ce364f26c905.zip |
#1976. A handlers' order has been changed. The javac's HandleDelegate generates code before the HandleVal.
Diffstat (limited to 'test/transform/resource/after-delombok/ValDelegateMethodReference.java')
-rw-r--r-- | test/transform/resource/after-delombok/ValDelegateMethodReference.java | 65 |
1 files changed, 65 insertions, 0 deletions
diff --git a/test/transform/resource/after-delombok/ValDelegateMethodReference.java b/test/transform/resource/after-delombok/ValDelegateMethodReference.java new file mode 100644 index 00000000..186e2aaa --- /dev/null +++ b/test/transform/resource/after-delombok/ValDelegateMethodReference.java @@ -0,0 +1,65 @@ +import java.util.function.Function; + +public class ValDelegateMethodReference { + public void config() { + final Column<Entity, java.lang.String> column = createColumn(Entity::getValue); + } + + private <V> Column<Entity, V> createColumn(Function<Entity, V> func) { + return new Column<>(func); + } +} + +class Column<T, V> { + public Column(Function<T, V> vp) { + } +} + +class Entity { + private MyDelegate innerDelegate; + + @java.lang.SuppressWarnings("all") + public java.lang.String getValue() { + return this.innerDelegate.getValue(); + } + + @java.lang.SuppressWarnings("all") + public java.lang.Boolean getABoolean() { + return this.innerDelegate.getABoolean(); + } + + @java.lang.SuppressWarnings("all") + public void setValue(final java.lang.String value) { + this.innerDelegate.setValue(value); + } + + @java.lang.SuppressWarnings("all") + public void setABoolean(final java.lang.Boolean aBoolean) { + this.innerDelegate.setABoolean(aBoolean); + } +} + +class MyDelegate { + private String value; + private Boolean aBoolean; + + @java.lang.SuppressWarnings("all") + public String getValue() { + return this.value; + } + + @java.lang.SuppressWarnings("all") + public Boolean getABoolean() { + return this.aBoolean; + } + + @java.lang.SuppressWarnings("all") + public void setValue(final String value) { + this.value = value; + } + + @java.lang.SuppressWarnings("all") + public void setABoolean(final Boolean aBoolean) { + this.aBoolean = aBoolean; + } +}
\ No newline at end of file |