boolean ( ClassNode node, boolean hasAnnotation, boolean init, boolean throwsExceptions, int paramCount, int methodAccessFlags ) { if (!init || hasAnnotation|| throwsExceptions || paramCount > 0 || !DecompilerContext.getOption(IFernflowerPreferences.HIDE_DEFAULT_CONSTRUCTOR)) { return false; } StructClass cl = node.getWrapper().getClassStruct(); int classAccessFlags = node.type == ClassNode.CLASS_ROOT ? cl.getAccessFlags() : node.access; boolean isEnum = cl.hasModifier(CodeConstants.ACC_ENUM) && DecompilerContext.getOption(IFernflowerPreferences.DECOMPILE_ENUM); // default constructor requires same accessibility flags. Exception: enum constructor which is always private if (!isEnum && ((classAccessFlags & ACCESSIBILITY_FLAGS) != (methodAccessFlags & ACCESSIBILITY_FLAGS))) { return false; } int count = 0; for (StructMethod mt : cl.getMethods()) { if (CodeConstants.INIT_NAME.equals(mt.getName()) && ++count > 1) { return false; } } return true; }