Class ResultMementoBasicStandard

  • All Implemented Interfaces:
    ResultMappingMementoNode, ResultMemento, ResultMementoBasic

    public class ResultMementoBasicStandard
    extends Object
    implements ResultMementoBasic
    Implementation of ResultMementoBasic for scalar (basic) results.

    Ultimately a scalar result is defined as a column name and a BasicType with the following notes:

    • For JPA mappings, the column name is required. For hbm.xml mappings, it is optional (positional)
    • Ultimately, when reading values, we need the BasicType. We know the BasicType in a few different ways:
      • If we know an explicit Type, that is used.
      • If we do not know the Type, but do know the Java type then we determine the BasicType based on the reported SQL type and its known mapping to the specified Java type
      • If we know neither, we use the reported SQL type and its recommended Java type to resolve the BasicType to use