- public boolean equals(Object other) {
- if (this == other) {
- return true;
- }
- if (!(other instanceof CentralV2UserApp)) {
- return false;
- }
- CentralV2UserApp castOther = (CentralV2UserApp) other;
- return Objects.equals(this.userId, castOther.userId) &&
- Objects.equals(this.app, castOther.app) &&
- Objects.equals(this.role, castOther.role) &&
- Objects.equals(this.priority, castOther.priority);
- }
+ public int hashCode() {
+ final int prime = 31;
+ int result = 1;
+ result = prime * result + ((app == null) ? 0 : app.hashCode());
+ result = prime * result + ((priority == null) ? 0 : priority.hashCode());
+ result = prime * result + ((role == null) ? 0 : role.hashCode());
+ result = prime * result + ((userId == null) ? 0 : userId.hashCode());
+ return result;
+ }
+
+ @Override
+ public boolean equals(Object other) {
+ if (this == other) {
+ return true;
+ }
+ if (!(other instanceof CentralV2UserApp)) {
+ return false;
+ }
+ CentralV2UserApp castOther = (CentralV2UserApp) other;
+ return Objects.equals(this.userId, castOther.userId) &&
+ Objects.equals(this.app, castOther.app) &&
+ Objects.equals(this.role, castOther.role) &&
+ Objects.equals(this.priority, castOther.priority);
+ }