Object Equality
The rules that decide when two objects should count as having the same value.
What is Object Equality in Java?
Object Equality — The rules that decide when two objects should count as having the same value.
record Product(String name) {
}
class ProductCheck {
boolean sameProduct(Product first, Product second) {
return first.equals(second);
}
}
Level: Journeyman · More Java terms at this level
Updated