org.springframework.data.repository.query

## Class SpelEvaluator

- java.lang.Object
- - org.springframework.data.repository.query.SpelEvaluator

    public class SpelEvaluator
    extends Object

Evaluates SpEL expressions as extracted by the `SpelQueryContext.SpelExtractor` based on parameter information from a method and parameter values from a method call.

Since:
  2.1
Author:
  Jens Schauder, Gerrit Meier, Oliver Gierke
See Also:
  `SpelQueryContext#parse(String, Parameters)`

### Constructor Summary

Constructors
Constructor and Description
`SpelEvaluator(QueryMethodEvaluationContextProvider evaluationContextProvider, Parameters<?,?> parameters, SpelQueryContext.SpelExtractor extractor)`

### Method Summary

All Methods Instance Methods Concrete Methods
`Map<String,Object>` `evaluate(Object[] values)` Evaluate all the SpEL expressions in `#parameterNameToSpelMap` based on values provided as an argument.
`String` `getQueryString()` Returns the query string produced by the intermediate SpEL expression collection step.

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Constructor Detail

#### SpelEvaluator

    public SpelEvaluator(QueryMethodEvaluationContextProvider evaluationContextProvider,
                         Parameters<?,?> parameters,
                         SpelQueryContext.SpelExtractor extractor)

### Method Detail

#### evaluate

    public Map<String,Object> evaluate(Object[] values)

Evaluate all the SpEL expressions in `#parameterNameToSpelMap` based on values provided as an argument.

Parameters:
  `values` - Parameter values. Must not be null.
Returns:
  a map from parameter name to evaluated value. Guaranteed to be not null.

#### getQueryString

    public String getQueryString()

Returns the query string produced by the intermediate SpEL expression collection step.

Returns: