class JcrProperties implements ProgressCheckFactory {

    @Override
    public ProgressCheck newInstance(final JsonObject config) {
        List<Rule> pathScope = Rules.fromJsonArray(arrayOrEmpty(config, keys().scopePaths()));

        List<String> denyNodeTypes = mapArrayOfStrings(arrayOrEmpty(config, keys().denyNodeTypes()));
        List<String> nodeTypeScope = mapArrayOfStrings(arrayOrEmpty(config, keys().scopeNodeTypes()));
        final ResourceBundleHolder resourceBundleHolder = new ResourceBundleHolder();
        List<JcrPropertyConstraints> propertyChecks = JcrPropertyConstraints
                .fromJsonArray(resourceBundleHolder::getResourceBundle, arrayOrEmpty(config, keys().properties()));
        return new Check(pathScope, denyNodeTypes, nodeTypeScope, propertyChecks, resourceBundleHolder);
    }

}