Class UpdateObjectDescImpl

    • Constructor Detail

      • UpdateObjectDescImpl

        public UpdateObjectDescImpl​(Class pcClass)
    • Method Detail

      • reset

        public void reset()
      • hasUpdatedFields

        public boolean hasUpdatedFields()
      • getUpdatedJoinTableFields

        public Collection getUpdatedJoinTableFields()
      • hasUpdatedJoinTableRelationships

        public boolean hasUpdatedJoinTableRelationships()
      • hasModifiedLobField

        public boolean hasModifiedLobField()
        Returns true if any of the changed fields is byte[].
      • markRelationshipChange

        public void markRelationshipChange​(FieldDesc fieldDesc)
        Marks the relationship change property for this instance, if the updated field is a relationship field or a hidden field tracing a foreign key column in the database.
        Parameters:
        fieldDesc - Updated field.
      • hasChangedRelationships

        public boolean hasChangedRelationships()
        Returns true, if this state manager has a changed relationship field.
        Returns:
        True, if this state manager has a changed relationship field.
      • clearUpdatedJoinTableRelationships

        public void clearUpdatedJoinTableRelationships()
      • recordUpdatedField

        public void recordUpdatedField​(LocalFieldDesc fieldDesc)
      • getUpdatedFields

        public List getUpdatedFields()
      • getUpdateAction

        public int getUpdateAction()
      • isBeforeImageRequired

        public boolean isBeforeImageRequired()
      • setConcurrency

        public void setConcurrency​(Concurrency concurrency)
      • setObjectInfo

        public void setObjectInfo​(StateManager biStateManager,
                                  StateManager aiStateManager,
                                  int action)
        We send the AfterImage for updates and inserts but for updates it will only hold values for updated attributes (unless the class is configured to send the whole AfterImage, also we'll let the concurrency interface affect the sent AfterImage (and the sent BeforeImage)). For deletes the AfterImage will be NIL, for inserts the BeforeImage will be NIL. For deletes the BeforeImage will contain values for all key attributes. Also for deletes and updates we'll send the HiddenValues array from the paladin (although we can set to NIL any values in the array not needed by this particular update). UpdatedAttributes will contain indexes into the PersistentDesc.Attributes array for new or updated values. Initially we'll probably just send the whole BeforeImage and AfterImage (except that we won't have an AfterImage for Deletes and we won't have a BeforeImage for updates).
        Specified by:
        setObjectInfo in interface UpdateObjectDesc
      • incrementVersion

        public void incrementVersion()
        Triggers the version update if the associated state manager is registered for version consistency and database fields have been modified. The version is incremented, if
        • The associated instance is version consistent.
        • The associated instance has updated database fields.
        Note: The version is not incremented, if a relationship mapped to a join table was updated.
      • setVerificationFailed

        public void setVerificationFailed()
        Marks the associated state manager as failed.
      • hasVersionConsistency

        public boolean hasVersionConsistency()