Usages of ResultTransformer were deprecated in 5.2. For 6.0 let's develop the better way to apply this idea, splitting this into 2 distinct functional contracts: TupleTransformer and ResultListTransformer.
There is some uncertainty we need to clarify with regards to how TupleTransformer and RowTransformer play together when the query is "typed".
The "highest level" of transformation is the type defined for a TypedQuery which defines the type of the individual "rows" returned by the Query to the user. This resultType may be:
Object.class to indicate that an Object should be the row type (so-called "pass thru" transformer).
Tuple.class which indicates that the results should be wrapped in a JPA Tuple
Some other value which indicates the expected row type. This is limited to cases where either:
the query defined a single "select expression" and the resultType names the type of that selection
the user supplied a TupleTransformer and the resultType names that TupleTransformer return type.
Some that we specifically need to decide on: