public static ConstructorBuilder getInstance(
                Configuration configuration,
                ClassDoc classDoc,
                ConstructorWriter writer) {
                ConstructorBuilder builder = new ConstructorBuilder(configuration);
                builder.classDoc = classDoc;
                builder.writer = writer;
                builder.visibleMemberMap =
                        new VisibleMemberMap(
                                classDoc,
                                VisibleMemberMap.CONSTRUCTORS,
                                configuration.nodeprecated);
                builder.constructors =
                        new ArrayList(builder.visibleMemberMap.getMembersFor(classDoc));
                for (int i = 0; i < builder.constructors.size(); i++) {
                        if (((ProgramElementDoc) (builder.constructors.get(i)))
                                .isProtected()
                                || ((ProgramElementDoc) (builder.constructors.get(i)))
                                        .isPrivate()) {
                                writer.setFoundNonPubConstructor(true);
                        }
                }
                if (configuration.getMemberComparator() != null) {
                        Collections.sort(
                                builder.constructors,
                                configuration.getMemberComparator());
                }
                return builder;
        }