本文整理了Java中org.jboss.errai.codegen.meta.MetaClass.getParametersAnnotatedWith()
方法的一些代码示例,展示了MetaClass.getParametersAnnotatedWith()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。MetaClass.getParametersAnnotatedWith()
方法的具体详情如下:
包路径:org.jboss.errai.codegen.meta.MetaClass
类名称:MetaClass
方法名:getParametersAnnotatedWith
暂无
代码示例来源:origin: errai/errai
@SuppressWarnings({ "unchecked", "rawtypes" })
private List<HasAnnotations> getAnnotatedWithForElementType(final MetaClass type, final ElementType elemType, final Class<? extends Annotation> annoType) {
final List annotatedItems;
switch (elemType) {
case FIELD:
annotatedItems = type.getFieldsAnnotatedWith(annoType);
break;
case METHOD:
annotatedItems = type.getMethodsAnnotatedWith(annoType);
break;
case PARAMETER:
annotatedItems = type.getParametersAnnotatedWith(annoType);
break;
case TYPE:
annotatedItems = (type.isAnnotationPresent(annoType)) ? Collections.singletonList(type) : Collections.emptyList();
break;
default:
throw new RuntimeException("Not yet implemented.");
}
return annotatedItems;
}
代码示例来源:origin: org.jboss.errai/errai-data-binding
final List<MetaParameter> modelParameters = decorable.getDecorableDeclaringType().getParametersAnnotatedWith(Model.class);
if (!modelParameters.isEmpty()) {
throw new GenerationException(
代码示例来源:origin: errai/errai
final List<MetaParameter> modelParameters = decorable.getDecorableDeclaringType().getParametersAnnotatedWith(Model.class);
if (!modelParameters.isEmpty()) {
throw new GenerationException(
内容来源于网络,如有侵权,请联系作者删除!