Package org.hibernate.dialect
Class StructHelper
java.lang.Object
org.hibernate.dialect.StructHelper
A Helper for serializing and deserializing struct, based on an
EmbeddableMappingType.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic StructAttributeValuesgetAttributeValues(EmbeddableMappingType embeddableMappingType, Object[] rawJdbcValues, WrapperOptions options) static ValuedModelPartgetEmbeddedPart(EmbeddableMappingType embeddableMappingType, int position) static intgetJdbcValueCount(MappingType mappedType) static Object[]getJdbcValues(EmbeddableMappingType embeddableMappingType, int[] orderMapping, Object domainValue, WrapperOptions options) static Objectinstantiate(EmbeddableMappingType embeddableMappingType, StructAttributeValues attributeValues, SessionFactoryImplementor sessionFactory) static voidorderJdbcValues(EmbeddableMappingType embeddableMappingType, int[] inverseMapping, Object[] sourceJdbcValues, Object[] targetJdbcValues) ThesourceJdbcValuesarray is ordered according to the expected physical order, as given through the argument order of @Instantiator.
-
Constructor Details
-
StructHelper
public StructHelper()
-
-
Method Details
-
getAttributeValues
public static StructAttributeValues getAttributeValues(EmbeddableMappingType embeddableMappingType, Object[] rawJdbcValues, WrapperOptions options) throws SQLException - Throws:
SQLException
-
getJdbcValues
public static Object[] getJdbcValues(EmbeddableMappingType embeddableMappingType, int[] orderMapping, Object domainValue, WrapperOptions options) throws SQLException - Throws:
SQLException
-
instantiate
public static Object instantiate(EmbeddableMappingType embeddableMappingType, StructAttributeValues attributeValues, SessionFactoryImplementor sessionFactory) -
getEmbeddedPart
public static ValuedModelPart getEmbeddedPart(EmbeddableMappingType embeddableMappingType, int position) -
orderJdbcValues
public static void orderJdbcValues(EmbeddableMappingType embeddableMappingType, int[] inverseMapping, Object[] sourceJdbcValues, Object[] targetJdbcValues) ThesourceJdbcValuesarray is ordered according to the expected physical order, as given through the argument order of @Instantiator. ThetargetJdbcValuesarray should be ordered according to the Hibernate internal ordering, which is based on property name. This method copies fromsourceJdbcValuestotargetJdbcValuesaccording to the ordering. -
getJdbcValueCount
-