[JPA_SPEC-2] Use of Parameter objects with StoredProcedureQuery Created: 05/Dec/11  Updated: 04/Apr/13  Resolved: 04/Apr/13

Status: Closed
Project: jpa-spec
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Improvement Priority: Major
Reporter: ldemichiel Assignee: Unassigned
Resolution: Works as designed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


The issue was previously raised in email discussion by Rainer:

Should we consider changing the return type of the register methods, as:

<T> Parameter<T> registerStoredProcedureParameter(
          int position,
          Class<T> type,
          ParameterMode mode)

<T> Parameter<T> registerStoredProcedureParameter(
          String parameterName,
          Class<T> type,
          ParameterMode mode)

which would enable us to add a method

<T> getOutputParameterValue(Parameter<T> param)

We could then say that the usage of a Parameter<T> object other than the ones created by one of the register methods is undefined for a certain StoredProcedure.

The change, and tradeoff to consider, is that the current registerStoredProcedureParameter methods return the StoredProcedureQuery object (which allows method chaining).

Comment by ldemichiel [ 04/Apr/13 ]

Consensus was to leave this as is, with support for chaining by return of StoredProcedureQuery object.

Generated at Mon Feb 27 13:08:07 UTC 2017 using JIRA 6.2.3#6260-sha1:63ef1d6dac3f4f4d7db4c1effd405ba38ccdc558.