mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
FacetAndType: +equals/hashCode
GitOrigin-RevId: 01a19f51150f2edfc06e2c8e699de79fb1edd570
This commit is contained in:
committed by
intellij-monorepo-bot
parent
467ac38954
commit
33043c8160
@@ -133,5 +133,19 @@ public abstract class FacetModelBase implements FacetModel {
|
||||
myFacet = facet;
|
||||
myTypeId = id;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean equals(Object o) {
|
||||
if (this == o) return true;
|
||||
if (o == null || getClass() != o.getClass()) return false;
|
||||
FacetAndType type = (FacetAndType)o;
|
||||
return Objects.equals(myFacet, type.myFacet) &&
|
||||
Objects.equals(myTypeId, type.myTypeId);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return Objects.hash(myFacet, myTypeId);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user