Above, I should have pointed out the importance of {{FunctionReturn}} extending {{ParameterRegistration}}. Essentially it allows access to the return value. Unlike JPA {{StoredProcedureQuery}}, Hibernate's native {{ProcedureCall}}/{{ProcedureOutputs}} allow access to parameter outputs via the parameter memento:
{code:title=ProcedureOutputs.java|borderStyle=solid} public interface ProcedureOutputs { ... public <T> T getOutputParameterValue(ParameterRegistration<T> parameterRegistration); } {code}
Having {{FunctionReturn}} extend {{ParameterRegistration}} allows the {{FunctionReturn}} to be passed back in here to retrieve the return value. The other (cleaner, imo) option is to simply define a new method:
{code:title=ProcedureOutputs.java|borderStyle=solid} public interface ProcedureOutputs { ... public Object getFunctionReturn(); } {code}
|