DoFirstWith2<A extends Comp<T> , B extends Comp<T> > method
void
DoFirstWith2<A extends Comp<T> , B extends Comp<T> >(
- void fn(
- E entity,
- A a,
- B b
Query-like Calls fn with the first matching element and its A
and B components. Does nothing if the result set is empty.
Implementation
void DoFirstWith2<
A extends Comp<T>,
B extends Comp<T>
>(void Function(E entity, A a, B b) fn) {
final entities = _resolve();
if (entities.isEmpty) return;
final entity = entities.first;
entity.on2<A, B>((a, b) => fn(entity, a, b));
}