I'm creating a UserQuery to get all online users which also have a specific attribute set on them. However, I cannot find a way to add a criterion for users that are online? Alternatively, is there a way to only do the query on a limited collection of (online) users?
At the present time the online system is note integrated in the query system. So it's impossible to do exactly this. I recommend you to maybe do the filtering in memory.