Skip to content

ResultSet: Implement interface Countable - #169

Merged
nilmerg merged 2 commits into
mainfrom
feature/implement-countable-in-resultset-168
Aug 11, 2026
Merged

ResultSet: Implement interface Countable#169
nilmerg merged 2 commits into
mainfrom
feature/implement-countable-in-resultset-168

Conversation

@nilmerg

@nilmerg nilmerg commented Aug 7, 2026

Copy link
Copy Markdown
Member

resolves #168

@nilmerg nilmerg added this to the v1.0.0 milestone Aug 7, 2026
@nilmerg nilmerg self-assigned this Aug 7, 2026
@nilmerg nilmerg added the enhancement New feature or request label Aug 7, 2026
@cla-bot cla-bot Bot added the cla/signed label Aug 7, 2026
Comment thread src/ResultSet.php Outdated
Comment thread src/ResultSet.php
@nilmerg
nilmerg force-pushed the feature/implement-countable-in-resultset-168 branch from 3432482 to dc933f9 Compare August 11, 2026 06:52
@nilmerg
nilmerg merged commit 39b5f80 into main Aug 11, 2026
13 checks passed
@nilmerg
nilmerg deleted the feature/implement-countable-in-resultset-168 branch August 11, 2026 06:54
nilmerg added a commit to Icinga/icinga-notifications-web that referenced this pull request Aug 11, 2026
This adds `Incidents::getRoles(\Icinga\User $user): \Generator` that
allows to fetch all incidents and roles for the given user. It's a
convenience method as it allows to quickly determine the current role of
said user and doesn't rely on the previously only available iteration
over all incidents.

An additional change, which should amplify the optimization benefit by
this in Icinga/icingadb-web#1392 is that
`Incidents::hasIncident()` does not always query all incidents now just
to answer the question that *any* incident exists.

requires Icinga/ipl-orm#169
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cla/signed enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Implement interface Countable in class ResultSet

2 participants