Class defineAccessClass (String name, byte[] bytes) throws ClassFormatError { localClassNames.add(name); return defineClass(name, bytes); }
Class<?> defineClass (String name, byte[] bytes) throws ClassFormatError { try { // Attempt to load the access class in the same loader, which makes protected and default access members accessible. return (Class<?>)getDefineClassMethod().invoke(getParent(), new Object[] {name, bytes, Integer.valueOf(0), Integer.valueOf(bytes.length), getClass().getProtectionDomain()}); } catch (Exception ignored) { // continue with the definition in the current loader (won't have access to protected and package-protected members) } return defineClass(name, bytes, 0, bytes.length, getClass().getProtectionDomain()); }
Class defineAccessClass (String name, byte[] bytes) throws ClassFormatError { localClassNames.add(name); return defineClass(name, bytes); }
Class<?> defineClassLocal(String name, byte[] bytes) throws ClassFormatError { locals.add(name); return defineClass(name,bytes); }
Class<?> defineClass (String name, byte[] bytes) throws ClassFormatError { try { // Attempt to load the access class in the same loader, which makes protected and default access members accessible. Method method = ClassLoader.class.getDeclaredMethod("defineClass", new Class[] {String.class, byte[].class, int.class, int.class, ProtectionDomain.class}); if (!method.isAccessible()) method.setAccessible(true); return (Class)method.invoke(getParent(), new Object[] {name, bytes, Integer.valueOf(0), Integer.valueOf(bytes.length), getClass().getProtectionDomain()}); } catch (Exception ignored) { } return defineClass(name, bytes, 0, bytes.length, getClass().getProtectionDomain()); }
Class<?> defineClass (String name, byte[] bytes) throws ClassFormatError { try { // Attempt to load the access class in the same loader, which makes protected and default access members accessible. Method method = ClassLoader.class.getDeclaredMethod("defineClass", new Class[] {String.class, byte[].class, int.class, int.class}); method.setAccessible(true); return (Class)method.invoke(getParent(), new Object[] {name, bytes, new Integer(0), new Integer(bytes.length)}); } catch (Exception ignored) { } return defineClass(name, bytes, 0, bytes.length); } }
Class<?> defineClass (String name, byte[] bytes) throws ClassFormatError { try { // Attempt to load the access class in the same loader, which makes protected and default access members accessible. return (Class<?>)getDefineClassMethod().invoke(getParent(), new Object[] {name, bytes, Integer.valueOf(0), Integer.valueOf(bytes.length), getClass().getProtectionDomain()}); } catch (Exception ignored) { // continue with the definition in the current loader (won't have access to protected and package-protected members) } return defineClass(name, bytes, 0, bytes.length, getClass().getProtectionDomain()); }
Class<?> defineClass (String name, byte[] bytes) throws ClassFormatError { try { // Attempt to load the access class in the same loader, which makes protected and default access members accessible. return (Class<?>)getDefineClassMethod().invoke(getParent(), new Object[] {name, bytes, Integer.valueOf(0), Integer.valueOf(bytes.length), getClass().getProtectionDomain()}); } catch (Exception ignored) { // continue with the definition in the current loader (won't have access to protected and package-protected members) } return defineClass(name, bytes, 0, bytes.length, getClass().getProtectionDomain()); }
accessClass = loader.defineClass(accessClassName, cw.toByteArray());
accessClass = loader.defineClass(accessClassName, data);
accessClass = loader.defineClass(accessClassName, data);
accessClass = loader.defineClass(accessClassName, data);
insertGetString(cw, classNameInternal, fields); cw.visitEnd(); accessClass = loader.defineClass(accessClassName, cw.toByteArray());