Interface TreeHook


@SupportedAll public interface TreeHook
A TreeHook encapsulates some functionality that should be executed at the end of a tree, after authentication. They can be added by nodes. The following parameters can be injected into the constructor of a class implementing this interface using the Assisted annotation:
  • SSOToken
  • - the token containing details of the new session created on successful completion of an authentication journey
  • Response
  • - the response sent to the user on successful completion of an authentication journey
  • Request
  • - the request submitted by the user agent
  • Realm
  • - the realm in which the authentication is taking place
  • config
  • - the node configuration object; the type of this configuration is defined by the annotation
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Interface
    Description
    static @interface 
    Annotation that describes the metadata of the node.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final String
    Arguments for the session hook.
    static final String
    Node config key.
    static final String
    Node ID key.
    static final String
    Node type key.
    static final String
    Session hook class key.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Main method that will contain the logic that needs to be executed when the session hook is called.
    default void
    Main method that will contain the logic that needs to be executed on tree exception.
    default void
    Main method that will contain the logic that needs to be executed on tree failure.
  • Field Details

  • Method Details

    • accept

      void accept() throws TreeHookException
      Main method that will contain the logic that needs to be executed when the session hook is called.
      Throws:
      TreeHookException - if an exception occurs.
    • acceptFailure

      default void acceptFailure() throws TreeHookException
      Main method that will contain the logic that needs to be executed on tree failure. The session cannot be read or modified on failure.
      Throws:
      TreeHookException - if an exception occurs.
    • acceptException

      default void acceptException() throws TreeHookException
      Main method that will contain the logic that needs to be executed on tree exception. The session cannot be read or modified on exception.
      Throws:
      TreeHookException - if an exception occurs.