private static ConditionOutcome getConditionOutcome(
        final ConditionContext context,
        final CasFeatureModule.FeatureCatalog[] features,
        final String module,
        final boolean enabledByDefault) {

        val selectedModules = context.getEnvironment().getProperty(PROPERTY_SELECTED_FEATURE_MODULES, StringUtils.EMPTY);
        if (StringUtils.isNotBlank(selectedModules)) {
            return verifySelectedFeatureModules(features, module, selectedModules);
        }
        
        for (val feature : features) {
            val property = feature.toProperty(module);
            LOGGER.trace("Checking for feature module capability via [{}]", property);

            val isFeatureDisabled = !context.getEnvironment().containsProperty(property) && !enabledByDefault;
            if (isFeatureDisabled) {
                val message = "CAS feature " + property + " is disabled by default and must be explicitly enabled.";
                LOGGER.trace(message);
                return ConditionOutcome.noMatch(message);
            }

            val propertyValue = context.getEnvironment().getProperty(property);
            if (StringUtils.equalsIgnoreCase(propertyValue, "false")) {
                val message = "CAS feature " + property + " is set to false.";
                LOGGER.trace(message);
                return ConditionOutcome.noMatch(message);
            }
            val message = "CAS feature " + property + " is set to true.";
            LOGGER.trace(message);
            feature.register(module);
        }
        
        return ConditionOutcome.match("Requested features " + Arrays.toString(features) + " are enabled");
    }
This is {@link CasFeatureEnabledCondition}.

@author Misagh Moayyed
@since 6.5.0
core/cas-server-core-util-api/src/main/java/org/apereo/cas/util/spring/boot/CasFeatureEnabledCondition.java