本文整理了Java中org.jboss.errai.codegen.meta.MetaClass.getDeclaredConstructors()
方法的一些代码示例,展示了MetaClass.getDeclaredConstructors()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。MetaClass.getDeclaredConstructors()
方法的具体详情如下:
包路径:org.jboss.errai.codegen.meta.MetaClass
类名称:MetaClass
方法名:getDeclaredConstructors
暂无
代码示例来源:origin: errai/errai
@Override
public List<MetaParameter> getParametersAnnotatedWith(final Class<? extends Annotation> annotation) {
final List<MetaParameter> methods = new ArrayList<>();
MetaClass scanTarget = this;
while (scanTarget != null) {
for (final MetaConstructor m : scanTarget.getDeclaredConstructors()) {
methods.addAll(m.getParametersAnnotatedWith(annotation));
}
for (final MetaMethod m : scanTarget.getDeclaredMethods()) {
methods.addAll(m.getParametersAnnotatedWith(annotation));
}
scanTarget = scanTarget.getSuperClass();
}
return methods;
}
代码示例来源:origin: org.jboss.errai/errai-codegen
@Override
public List<MetaParameter> getParametersAnnotatedWith(final Class<? extends Annotation> annotation) {
final List<MetaParameter> methods = new ArrayList<>();
MetaClass scanTarget = this;
while (scanTarget != null) {
for (final MetaConstructor m : scanTarget.getDeclaredConstructors()) {
methods.addAll(m.getParametersAnnotatedWith(annotation));
}
for (final MetaMethod m : scanTarget.getDeclaredMethods()) {
methods.addAll(m.getParametersAnnotatedWith(annotation));
}
scanTarget = scanTarget.getSuperClass();
}
return methods;
}
代码示例来源:origin: errai/errai
@Test
public void testGetDeclaredConstructors() throws Exception {
final MetaClass mc = getMetaClass(HasManyConstructors.class);
final MetaConstructor[] ctors = mc.getDeclaredConstructors();
assertEquals("Not all constructors were returned.", 4, ctors.length);
}
代码示例来源:origin: org.jboss.errai/errai-marshalling
final MappingDefinition definition = new MappingDefinition(toMap, false);
for (final MetaConstructor c : toMap.getDeclaredConstructors()) {
final List<Boolean> hasMapsTos = new ArrayList<>();
if (c.getParameters().length != 0) {
代码示例来源:origin: errai/errai
final MappingDefinition definition = new MappingDefinition(toMap, false);
for (final MetaConstructor c : toMap.getDeclaredConstructors()) {
final List<Boolean> hasMapsTos = new ArrayList<>();
if (c.getParameters().length != 0) {
代码示例来源:origin: org.jboss.errai/errai-codegen
for (final MetaConstructor c : clazz.getDeclaredConstructors()) {
final BuildMetaConstructor newConstructor = new BuildMetaConstructor(buildMetaClass, EmptyStatement.INSTANCE,
GenUtil.scopeOf(c),
代码示例来源:origin: errai/errai
for (final MetaConstructor c : clazz.getDeclaredConstructors()) {
final BuildMetaConstructor newConstructor = new BuildMetaConstructor(buildMetaClass, EmptyStatement.INSTANCE,
GenUtil.scopeOf(c),
内容来源于网络,如有侵权,请联系作者删除!