Iterable<T> getAnnotations<T>([Type? type]) => _clazz.annotations .whereType<T>() .where((a) => type == null ? true : a.runtimeType == type);