File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -49229,7 +49229,7 @@ result in an exception as a custom `CacheManager` will be ignored by the
49229
49229
===== Conditional caching
49230
49230
Sometimes, a method might not be suitable for caching all the time (for example, it
49231
49231
might depend on the given arguments). The cache annotations support such functionality
49232
- through the `conditional ` parameter which takes a `SpEL` expression that is evaluated to
49232
+ through the `condition ` parameter which takes a `SpEL` expression that is evaluated to
49233
49233
either `true` or `false`. If `true`, the method is cached - if not, it behaves as if the
49234
49234
method is not cached, that is executed every since time no matter what values are in the
49235
49235
cache or what arguments are used. A quick example - the following method will be cached
@@ -49242,8 +49242,8 @@ only if the argument `name` has a length shorter than 32:
49242
49242
public Book findBook(String name)
49243
49243
----
49244
49244
49245
- In addition the `conditional ` parameter, the `unless` parameter can be used to veto the
49246
- adding of a value to the cache. Unlike `conditional `, `unless` expressions are evaluated
49245
+ In addition the `condition ` parameter, the `unless` parameter can be used to veto the
49246
+ adding of a value to the cache. Unlike `condition `, `unless` expressions are evaluated
49247
49247
__after__ the method has been called. Expanding on the previous example - perhaps we
49248
49248
only want to cache paperback books:
49249
49249
You can’t perform that action at this time.
0 commit comments