RootEntityResultTransformer, but we also distinct
the entity in the final result.
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 DistinctRootEntityResultTransformer |
| 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 List | Returns: The transformed List.The list to transform. list)Implements org. DistinctResultTransformer#transformList.
|
| public Object | Returns: The transformed tuple row.The tuple to transform tuple, String[] The tuple aliases aliases)Implements org. RootEntityResultTransformer#transformTuple.
|
| INSTANCE | back to summary |
|---|---|
| public static final DistinctRootEntityResultTransformer INSTANCE | |
| DistinctRootEntityResultTransformer | back to summary |
|---|---|
| private DistinctRootEntityResultTransformer() Disallow instantiation of DistinctRootEntityResultTransformer. | |
| 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. | |
| transformList | back to summary |
|---|---|
| public List Implements org. Simply delegates to | |
| transformTuple | back to summary |
|---|---|
| public Object transformTuple(Object[] tuple, String[] aliases) Implements org. Simply delegates to | |