boolean (Object obj) { if (!(obj instanceof MyKey && guardId.equals(((MyKey)obj).guardId))) return false; if (userObject == ((MyKey)obj).userObject) { return true; } if (myCallEquals || ((MyKey)obj).myCallEquals) { return userObject.equals(((MyKey)obj).userObject); } return false; }