Class CascadeLockingPolicy


  • public class CascadeLockingPolicy
    extends java.lang.Object
    INTERNAL:
    • Field Detail

      • m_parentClass

        protected java.lang.Class m_parentClass
      • m_lookForParentMapping

        protected boolean m_lookForParentMapping
      • m_shouldHandleUnmappedFields

        protected boolean m_shouldHandleUnmappedFields
      • m_hasCheckedForUnmappedFields

        protected boolean m_hasCheckedForUnmappedFields
      • m_unmappedFieldsQuery

        protected DataReadQuery m_unmappedFieldsQuery
    • Method Detail

      • getParentMapping

        protected DatabaseMapping getParentMapping()
        INTERNAL:
      • getParentDescriptorFromInheritancePolicy

        protected ClassDescriptor getParentDescriptorFromInheritancePolicy​(java.lang.Object parentObj)
        Get the descriptor that really represents this object In the case of inheritance, the object may represent a subclass of class the descriptor represents. If there is no InheritancePolicy, we return our parentDescriptor If there is inheritance we will search for a descriptor that represents parentObj and return that descriptor
        Parameters:
        parentObj -
        Returns:
      • getMappedTranslationRow

        protected AbstractRecord getMappedTranslationRow​(java.lang.Object changedObj,
                                                         UnitOfWorkImpl uow)
        INTERNAL:
      • getUnmappedTranslationRow

        protected AbstractRecord getUnmappedTranslationRow​(java.lang.Object changedObj,
                                                           UnitOfWorkImpl uow)
        INTERNAL:
      • initUnmappedFields

        public void initUnmappedFields​(UnitOfWorkImpl uow)
        INTERNAL: Identify mapped and not mapped fields (should be done once). The result - either two non-empty Maps m_unmappedQueryKeyFields and m_mappedQueryKeyFields, or m_unmappedQueryKeyFields == null and m_mappedQueryKeyFields == m_queryKeyFields.
      • initUnmappedFieldsQuery

        public void initUnmappedFieldsQuery​(UnitOfWorkImpl uow)
        INTERNAL: This method called in case there are m_unmappedQueryKeyFields. It creates a query that would fetch the values for this fields from the db.
      • setQueryKeyFields

        public void setQueryKeyFields​(java.util.Map<DatabaseField,​DatabaseField> queryKeyFields,
                                      boolean lookForParentMapping)
        INTERNAL:
      • setShouldHandleUnmappedFields

        public void setShouldHandleUnmappedFields​(boolean shouldHandleUnmappedFields)
        INTERNAL: Indicates whether to expect unmapped fields. That should be set to true for UnidirectionalOneToManyMapping.
      • shouldHandleUnmappedFields

        public boolean shouldHandleUnmappedFields()
        INTERNAL: