-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Add new helpful Entity Extensions #16457
Conversation
Any places in OC where these could be utilized? |
@Piedone I used one of the new extensions in OC now. The |
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.
Looks good, but please wait for the builds to finish. GitHub Actions has an issue right now where they're queued and their start is delayed: https://www.githubstatus.com/.
Adding the following helpful extensions to entity:
IEntity Alter<TAspect>(this IEntity entity, Action<TAspect> action)
bool TryGet<T>(this IEntity entity, out T aspect)
The new extensions simplify the following already existing extensions:
IEntity Alter<TAspect>(this IEntity entity, string name, Action<TAspect> action)
bool TryGet<T>(this IEntity entity, string name, out T aspect)