diff options
author | Roel Spilker <r.spilker@gmail.com> | 2015-10-26 22:21:16 +0100 |
---|---|---|
committer | Roel Spilker <r.spilker@gmail.com> | 2015-10-26 22:21:16 +0100 |
commit | 30cfbcf9e42f9f997817ad0d097b71655f9a8485 (patch) | |
tree | 62117de2fff9a60a9fa4e2ae85065229be73a441 /test/transform/resource/after-delombok/EqualsAndHashcodeOfExclude.java | |
parent | be2dfb3d9de2336657481d473bf69c275c4b7437 (diff) | |
download | lombok-30cfbcf9e42f9f997817ad0d097b71655f9a8485.tar.gz lombok-30cfbcf9e42f9f997817ad0d097b71655f9a8485.tar.bz2 lombok-30cfbcf9e42f9f997817ad0d097b71655f9a8485.zip |
Add tests for `@EqualsAndHashCode` for the attributes `of` and `exclude`
Diffstat (limited to 'test/transform/resource/after-delombok/EqualsAndHashcodeOfExclude.java')
-rw-r--r-- | test/transform/resource/after-delombok/EqualsAndHashcodeOfExclude.java | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/test/transform/resource/after-delombok/EqualsAndHashcodeOfExclude.java b/test/transform/resource/after-delombok/EqualsAndHashcodeOfExclude.java new file mode 100644 index 00000000..ae7b8451 --- /dev/null +++ b/test/transform/resource/after-delombok/EqualsAndHashcodeOfExclude.java @@ -0,0 +1,46 @@ +final class EqualsAndHashCodeOf { + int x; + int y; + @java.lang.Override + @java.lang.SuppressWarnings("all") + @javax.annotation.Generated("lombok") + public boolean equals(final java.lang.Object o) { + if (o == this) return true; + if (!(o instanceof EqualsAndHashCodeOf)) return false; + final EqualsAndHashCodeOf other = (EqualsAndHashCodeOf)o; + if (this.x != other.x) return false; + return true; + } + @java.lang.Override + @java.lang.SuppressWarnings("all") + @javax.annotation.Generated("lombok") + public int hashCode() { + final int PRIME = 59; + int result = 1; + result = result * PRIME + this.x; + return result; + } +} +final class EqualsAndHashCodeExclude { + int x; + int y; + @java.lang.Override + @java.lang.SuppressWarnings("all") + @javax.annotation.Generated("lombok") + public boolean equals(final java.lang.Object o) { + if (o == this) return true; + if (!(o instanceof EqualsAndHashCodeExclude)) return false; + final EqualsAndHashCodeExclude other = (EqualsAndHashCodeExclude)o; + if (this.x != other.x) return false; + return true; + } + @java.lang.Override + @java.lang.SuppressWarnings("all") + @javax.annotation.Generated("lombok") + public int hashCode() { + final int PRIME = 59; + int result = 1; + result = result * PRIME + this.x; + return result; + } +}
\ No newline at end of file |