Class<?> defineClass(String name, byte[] bcode, int off, int len, Class<?> neighbor, ClassLoader loader, ProtectionDomain protectionDomain) throws ClassFormatError, CannotCompileException { if (neighbor != null) return toClass(neighbor, bcode); else { // Lookup#defineClass() is not available. So fallback to invoking defineClass on // ClassLoader, which causes a warning message. return super.defineClass(name, bcode, off, len, neighbor, loader, protectionDomain); } } }