code: protected LdapSearchScope processLdapSearchScope(String name, String expression, LdapSearchScope value, boolean immediateOnly) {
          LdapSearchScope result;
          boolean immediate = false;
  
          /*
           * The expression language value takes precedence over the direct setting.
           */
          if (expression.isEmpty()) {
              /*
               * Direct setting.
               */
              result = value;
          } else {
              /*
               * Evaluate the EL expression to get the value.
               */
              Object obj = evaluateElExpression(expression);
              if (obj instanceof LdapSearchScope) {
                  result = (LdapSearchScope) obj;
                  immediate = isImmediateExpression(expression);
              } else if (obj instanceof String) {
                  result = LdapSearchScope.valueOf(((String) obj).toUpperCase());
                  immediate = isImmediateExpression(expression);
              } else {
                  throw new IllegalArgumentException("Expected '" + name + "' to evaluate to an LdapSearchScope type.");
              }
          }
  
          return (immediateOnly && !immediate) ? null : result;
      }
docs: This method will process a configuration value for LdapSearchScope setting in
  {@link LdapIdentityStoreDefinition}. It will first check to see if there is an
  EL expression. It there is, it will return the evaluated expression; otherwise, it
  will return the non-EL value.
  
  @param name The name of the property. Used for error messages.
  @param expression The EL expression returned from from the identity store definition.
  @param value The non-EL value.
  @param immediateOnly Return null if the value is a deferred EL expression.
  @return Either the evaluated EL expression or the non-EL value.