revapi/src/main/java/org/revapi/configuration/ConfigurationValidator.java
/**
     * Validates that the full configuration contains valid configuration for given configurable.
     *
     * @param fullConfiguration the full configuration containing properties for all configurables
     * @param configurable      the configurable to validate the configuration for
     *
     * @return the result of the validation.
     *
     * @throws ConfigurationException if reading the JSON schemas of the configurable failed
     */
Validates that the full configuration contains valid configuration for given configurable.
@param fullConfiguration the full configuration containing properties for all configurables
@param configurable      the configurable to validate the configuration for

@return the result of the validation.

@throws ConfigurationException if reading the JSON schemas of the configurable failed
Validates that the full configuration contains valid configuration for given configurable . @param fullConfiguration the full configuration containing properties for all configurables @param configurable the configurable to validate the configuration for @return the result of the validation . @throws ConfigurationException if reading the JSON schemas of the configurable failed
public ValidationResult validate(@Nonnull ModelNode fullConfiguration, @Nonnull Configurable configurable)
        throws ConfigurationException {
        try {
            switch (fullConfiguration.getType()) {
                case LIST:
                    return _validate(fullConfiguration, configurable);
                case UNDEFINED:
                    return ValidationResult.success();
                default:
                    throw new ConfigurationException("Expecting a JSON array as the configuration object.");
            }
        } catch (IOException | ScriptException e) {
            throw new ConfigurationException("Failed to validate configuration.", e);
        }
    }
public ValidationResult validate ( @ Nonnull ModelNode fullConfiguration , @ Nonnull Configurable configurable ) throws ConfigurationException { try { switch ( fullConfiguration . getType ( ) ) { case LIST : return _validate ( fullConfiguration , configurable ) ; case UNDEFINED : return ValidationResult . success ( ) ; default : throw new ConfigurationException ( "Expecting a JSON array as the configuration object." ) ; } } catch ( IOException | ScriptException e ) { throw new ConfigurationException ( "Failed to validate configuration." , e ) ; } }
Validates that the full configuration contains valid configuration for given configurable.
Validates that the full configuration contains valid configuration for given configurable .