code: protected boolean isValidScheme(String scheme) {
          if (scheme == null) {
              return false;
          }
          
          // TODO could be removed if external schemes were checked in the ctor before being stored
          if (!SCHEME_PATTERN.matcher(scheme).matches()) {
              return false;
          }
          
          if (isOff(ALLOW_ALL_SCHEMES) && !allowedSchemes.contains(scheme.toLowerCase(Locale.ENGLISH))) {
              return false;
          }
          
          return true;
      }
docs: Validate scheme. If schemes[] was initialized to a non null,
  then only those schemes are allowed.
  Otherwise the default schemes are "http", "https", "ftp".
  Matching is case-blind.
  @param scheme The scheme to validate.  A <code>null</code> value is considered
  invalid.
  @return true if valid.