|
From: <tri...@tr...> - 2003-07-23 21:59:37
|
Jürgen & Jean-Pierre,
> Let me refine your proposal a bit. We would need "Map context" on
> MappingSqlQueryWithParameters too, to be able to cascade down to the simpler
> mapRow methods. But why not avoid MappingSqlQueryWithContext in the first
> place and just add "Map context" to MappingSqlQueryWithParameters?
>
> MappingSqlQueryWithParameters
> abstract Object mapRow(ResultSet rs, int rowNum, Object[] parameters, Map
> context)
>
> MappingSqlQuery
> abstract Object mapRow(ResultSet rs, int rowNum)
>
> Whoever wants to use the context map will probably not mind the parameters
> even if they are not needed. Of course, existing custom subclasses of
> MappingSqlQueryWithParameters would still need to be changed then. But I
> don't consider that a problem, as I assume that most users use
> MappingSqlQuery anyway, and as migration is straightforward.
I'm OK with this solution.
Only other fully backward compatible solution would be:
MappingSqlQueryWithParametersAndContext
| |
| |
MappingSqlQueryWithParameters MappingSqlQueryWithContext
|
|
MappingSqlQuery
And that seems a bit too much.
Thomas
|