[#4107] Add Routine.getReturnParameter()

This commit is contained in:
lukaseder 2015-03-02 14:24:37 +01:00
parent 27d26848d2
commit cd58f9879a
2 changed files with 16 additions and 6 deletions

View File

@ -109,6 +109,15 @@ public interface Routine<T> extends QueryPart {
*/
Package getPackage();
/**
* The parameter representing this routine's {@link #getReturnValue()}
*
* @return The return parameter or <code>null</code> if this routine doesn't
* have a return value.
* @see #getParameters()
*/
Parameter<T> getReturnParameter();
/**
* A list of OUT parameters passed to the stored procedure as argument. This
* list contains all parameters that are either OUT or INOUT in their
@ -129,6 +138,11 @@ public interface Routine<T> extends QueryPart {
*/
List<Parameter<?>> getInParameters();
/**
* @return A list of parameters passed to the stored object as argument
*/
List<Parameter<?>> getParameters();
/**
* @return The routine's return value (if it is a function)
*/
@ -139,11 +153,6 @@ public interface Routine<T> extends QueryPart {
*/
List<Result<Record>> getResults();
/**
* @return A list of parameters passed to the stored object as argument
*/
List<Parameter<?>> getParameters();
/**
* Execute the stored object using a {@link Configuration} object
*

View File

@ -688,7 +688,8 @@ public abstract class AbstractRoutine<T> extends AbstractQueryPart implements Ro
return name;
}
protected final Parameter<?> getReturnParameter() {
@Override
public final Parameter<T> getReturnParameter() {
return returnParameter;
}