-
-
Notifications
You must be signed in to change notification settings - Fork 12
Implementation Role Feature 15
Max Leuthäuser edited this page Oct 16, 2015
·
3 revisions
An object and its roles have different identities
This view, which is quite singular, is a tribute to the so-called counting problem. It refers to the situation in which instances counted in their roles yield a greater number than the same instances counted by the objects playing the roles. For example, the number of passengers taking a certain means of transportation in one week may be greater than the number of individual persons traveling with that means during the same period.
None.
You can always override the equals
and hashCode
functions on your role classes to implement you own custom identity behavior.