Exactly how you have written it. It will only work if your equals (and possibly hashcode) method returns the correct value.
Type: Posts; User: Junky
Exactly how you have written it. It will only work if your equals (and possibly hashcode) method returns the correct value.
Does your Player class have an equals method?
Does your equals method have correct behaviour?