/** * Helper method to create a bean mixin. For finer control over the generated instance, use a new * instance of <code>Mixin</code> instead of this static method. TODO */ public static Mixin createBean(ClassLoader loader, Object[] beans) { Generator gen = new Generator(); gen.setStyle(STYLE_BEANS); gen.setDelegates(beans); gen.setClassLoader(loader); return gen.create(); }
/** * Helper method to create an interface mixin. For finer control over the generated instance, use * a new instance of <code>Mixin</code> instead of this static method. TODO */ public static Mixin create(Class[] interfaces, Object[] delegates) { Generator gen = new Generator(); gen.setClasses(interfaces); gen.setDelegates(delegates); return gen.create(); }
/** * Helper method to create an interface mixin. For finer control over the generated instance, use * a new instance of <code>Mixin</code> instead of this static method. TODO */ public static Mixin create(Object[] delegates) { Generator gen = new Generator(); gen.setDelegates(delegates); return gen.create(); }