move AddEventDetector under /sample, because it's not standard-compatible and should be defined as user class