private UrlValidator getUrlValidator() {
        if (this.urlValidatorWithRegex != null) {
            return urlValidatorWithRegex;
        }

        if (this.allowLocalUrls) {
            return URL_VALIDATOR_ALLOW_LOCAL_URLS;
        }

        return UrlValidator.getInstance();
    }
The factory to build a {@link org.apereo.cas.web.UrlValidator}.

@author swoeste
@since 5.2.0
core/cas-server-core-web-api/src/main/java/org/apereo/cas/web/SimpleUrlValidatorFactoryBean.java