Interface PersistHookExecutor

  • All Known Implementing Classes:
    DefaultPersistHookExecutor

    public interface PersistHookExecutor
    A service for executing persistence hooks.
    • Method Detail

      • runPrePersistHook

        java.util.Optional<ItemModel> runPrePersistHook​(java.lang.String hookName,
                                                        ItemModel item,
                                                        java.lang.String integrationKey)
        Executes a PrePersistHook on an item model
        Parameters:
        hookName - name of the PrePersistHook Spring bean in the application context to execute.
        item - an item to execute the PrePersistHook with.
        integrationKey - for the current item that is being created or updated
        Returns:
        item modified by the hook or empty.
        See Also:
        PrePersistHook.execute(ItemModel)
      • runPostPersistHook

        void runPostPersistHook​(java.lang.String hookName,
                                ItemModel item,
                                java.lang.String integrationKey)
        Executes a PostPersistHook on an item model
        Parameters:
        hookName - name of the PostPersistHook Spring bean in the application context to execute.
        item - an item to execute the PostPersistHook with.
        integrationKey - for the current item that is being created or updated
        See Also:
        PostPersistHook.execute(ItemModel)