ResultTransformer implementation which limits the result tuple
to only the "root entity".
Since this transformer is stateless, all instances would be considered equal.
So for optimization purposes we limit it to a single, singleton instance.
| Modifier and Type | Field and Description |
|---|---|
| public static final RootEntityResultTransformer |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public boolean[] | includeInTransform(String[]
- the aliases that correspond to the tuple aliases, int - the number of elements in the tuple tupleLength)Implements org. |
| public boolean | isTransformedValueATupleElement(String[]
- the aliases that correspond to the tuple aliases, int - the number of elements in the tuple tupleLength)Implements org. |
| private Object | Returns: The singleton instance :INSTANCESerialization hook for ensuring singleton uniqueing. |
| public Object | transformTuple(Object[]
The result elements tuple, String[] The result aliases ("parallel" array to tuple) aliases)Overrides org. Implements org. |
| INSTANCE | back to summary |
|---|---|
| public static final RootEntityResultTransformer INSTANCE | |
| RootEntityResultTransformer | back to summary |
|---|---|
| private RootEntityResultTransformer() Disallow instantiation of RootEntityResultTransformer. | |
| includeInTransform | back to summary |
|---|---|
| public boolean[] includeInTransform(String[] aliases, int tupleLength) Implements org. Doc from org. Returns an array with the i-th element indicating whether the i-th element of the tuple is included in the transformed value. | |
| isTransformedValueATupleElement | back to summary |
|---|---|
| public boolean isTransformedValueATupleElement(String[] aliases, int tupleLength) Implements org. Doc from org. When a tuple is transformed, is the result a single element of the tuple? | |
| readResolve | back to summary |
|---|---|
| private Object readResolve() Serialization hook for ensuring singleton uniqueing. | |
| transformTuple | back to summary |
|---|---|
| public Object transformTuple(Object[] tuple, String[] aliases) Overrides org. Implements org. Return just the root entity from the row tuple.
| |