public interface ResultAdapter<E> extends Comparable<ResultAdapter>
This interface is used to encapsulate the process of adapting results from a data store operation to that of the invoked repository method.
| 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
|
E |
adapt(Invocation invocation,
Object originalValue)
Called when we need to adapt the result from an invocation to the result required by the repository method
|
int |
getPriority() |
compareToboolean accepts(Invocation invocation, Object originalValue)
invocation - the invocationoriginalValue - the original valueE adapt(Invocation invocation, Object originalValue)
invocation - the repository method invocationoriginalValue - the original value returned from a data store operationint getPriority()
Copyright © 2014–2016. All rights reserved.