private static <T> Constructor<T> findImplicitConstructorFor(Class<T> type) {
        @SuppressWarnings("unchecked")
        final Constructor<T>[] constructors = (Constructor<T>[]) type.getDeclaredConstructors();

        List<Constructor<T>> annotatedConstructors = Stream.of(constructors)
                .filter(c -> c.isAnnotationPresent(ConstructorProperties.class))
                .collect(Collectors.toList());

        if (annotatedConstructors.size() > 1) {
            throw new IllegalArgumentException(type + " may have at most one constructor annotated @ConstructorProperties");
        } else if (annotatedConstructors.size() == 1) {
            return annotatedConstructors.get(0);
        }

        if (constructors.length != 1) {
            throw new IllegalArgumentException(type + " must have exactly one constructor, or specify it with @JdbiConstructor or @ConstructorProperties");
        }
        return constructors[0];
    }
Find an invokable constructor.  Prefer an {@link JdbiConstructor} annotated
one if present.  Throws if multiple or zero candidates are found.

@param <T>  the type to inspect
@param type the type to inspect
@return the preferred constructor
core/src/main/java/org/jdbi/v3/core/mapper/reflect/JdbiConstructors.java