public class NullSimpleResultAdapter extends AbstractResultAdapter<Object>
This adapter will try to adapt a null value to a simple value. Simple here is defined as anything that is not an iterable, an iterator, or a future promise.
It adapts results if the return type is simple and the original value is null.
This adapter runs at the priority of -400.
| Constructor and Description |
|---|
NullSimpleResultAdapter() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
accepts(Invocation invocation,
Object originalValue)
Called to determine whether or not this adapter can adapt the original value passed down from a data
store operation to the type required by the repository method being invoked
|
Object |
adapt(Invocation invocation,
Object originalValue)
Called when we need to adapt the result from an invocation to the result required by the repository method
|
compareTo, getPrioritypublic boolean accepts(Invocation invocation, Object originalValue)
ResultAdapterinvocation - the invocationoriginalValue - the original valuepublic Object adapt(Invocation invocation, Object originalValue)
ResultAdapterinvocation - the repository method invocationoriginalValue - the original value returned from a data store operationCopyright © 2014–2016. All rights reserved.