public void defineAnnotatedMethodsIndividually(Class clazz) { TypePopulator populator; if (RubyInstanceConfig.FULL_TRACE_ENABLED || RubyInstanceConfig.REFLECTED_HANDLES) { // we want reflected invokers or need full traces, use default (slow) populator if (DEBUG) LOG.info("trace mode, using default populator"); populator = TypePopulator.DEFAULT; } else { try { String qualifiedName = "org.jruby.gen." + clazz.getCanonicalName().replace('.', '$'); if (DEBUG) LOG.info("looking for " + qualifiedName + AnnotationBinder.POPULATOR_SUFFIX); Class populatorClass = Class.forName(qualifiedName + AnnotationBinder.POPULATOR_SUFFIX); populator = (TypePopulator)populatorClass.newInstance(); } catch (Throwable t) { if (DEBUG) LOG.info("Could not find it, using default populator"); populator = TypePopulator.DEFAULT; } } populator.populate(this, clazz); }
public void defineAnnotatedMethodsIndividually(Class clazz) { TypePopulator populator; if (RubyInstanceConfig.FULL_TRACE_ENABLED || RubyInstanceConfig.REFLECTED_HANDLES) { // we want reflected invokers or need full traces, use default (slow) populator if (DEBUG) LOG.info("trace mode, using default populator"); populator = TypePopulator.DEFAULT; } else { try { String qualifiedName = "org.jruby.gen." + clazz.getCanonicalName().replace('.', '$'); if (DEBUG) LOG.info("looking for " + qualifiedName + AnnotationBinder.POPULATOR_SUFFIX); Class populatorClass = Class.forName(qualifiedName + AnnotationBinder.POPULATOR_SUFFIX); populator = (TypePopulator)populatorClass.newInstance(); } catch (Throwable t) { if (DEBUG) LOG.info("Could not find it, using default populator"); populator = TypePopulator.DEFAULT; } } populator.populate(this, clazz); }
public final void defineAnnotatedMethodsIndividually(Class clazz) { getRuntime().POPULATORS.get(clazz).populate(this, clazz); }
public final void defineAnnotatedMethodsIndividually(Class clazz) { getRuntime().POPULATORS.get(clazz).populate(this, clazz); }