Use consistent equals/hashCode/toString order
Ensure that `equals` `hashCode` and `toString` methods always appear in the same order. This aligns with the style used in Spring Framework. Issue gh-8945
This commit is contained in:
+8
-8
@@ -275,14 +275,6 @@ public class AuthenticationPrincipalArgumentResolverTests {
|
||||
this.property = toCopy.property;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int hashCode() {
|
||||
final int prime = 31;
|
||||
int result = 1;
|
||||
result = prime * result + ((this.property == null) ? 0 : this.property.hashCode());
|
||||
return result;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean equals(Object obj) {
|
||||
if (this == obj) {
|
||||
@@ -306,6 +298,14 @@ public class AuthenticationPrincipalArgumentResolverTests {
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int hashCode() {
|
||||
final int prime = 31;
|
||||
int result = 1;
|
||||
result = prime * result + ((this.property == null) ? 0 : this.property.hashCode());
|
||||
return result;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user