annotation method

ConstantReader annotation(
  1. Type macro, {
  2. Element? e,
})

Implementation

ConstantReader annotation(Type macro, {Element? e}) {
  if (null == e) {
    return ConstantReader(null);
  }
  final meta = TypeChecker.typeNamed(macro, inPackage: 'maas');
  return ConstantReader(meta.firstAnnotationOf(e));
}