callEvent method

void callEvent(
  1. ArtifactEvent event
)

Implementation

void callEvent(ArtifactEvent event) {
  for (EventListener i in listeners[event.runtimeType] ?? []) {
    if (event is CancellableEvent &&
        (event as CancellableEvent).cancelled &&
        i.annotation.ignoreCancelled) {
      continue;
    }

    i.handler(event);
  }
}