-
Notifications
You must be signed in to change notification settings - Fork 219
fix: rename getAssiciatedResource to getSecondaryResource #1100
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
I think that |
This will be the primary API that everybody will use if any, should be short, and it is pretty obvious I think mainly for The Maybe with the event sources is not that straigforward, but we use the same interface (maybe we should not?, ResourceOwner is not really used anywhere explicitly) |
Associated is quite explicit, in my opinion: it's the resource associated with the one we specify as a parameter. We could rename it something different but again, ideally, in a good API, one should not have to look at the type of an object to resolve any ambiguity on what a method does. |
I would then name is as
So it will be then straightforward that we get secondary resource (ideally) either from event source or (if the feature is used) dependent resource. |
Kudos, SonarCloud Quality Gate passed! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you!
getResource
is either called on event source or dependent resource. In both context it should be obivius fromgetResource
that it is about the resource dependent resource / or event source is managing / caching.