Class SubjectCanonicalizationContext

  • All Implemented Interfaces:
    Iterable<BaseContext>

    public final class SubjectCanonicalizationContext
    extends BaseContext
    A context that holds an input Subject to canonicalize into a principal name, and the collection of c14n flows to attempt.

    There are different use cases in the system for the c14n process, but all of them share the use of this context as the input and output mechanism.

    Parent:
    ProfileRequestContext
    Added:
    At the end of a login flow or before any other execution of the subject canonicalization flow
    • Constructor Detail

      • SubjectCanonicalizationContext

        public SubjectCanonicalizationContext()
        Constructor.
    • Method Detail

      • getSubject

        @Nullable
        public Subject getSubject()
        Get the Subject to canonicalize.
        Returns:
        Subject to canonicalize
      • getPrincipalName

        @Nullable
        public String getPrincipalName()
        Get the canonical principal name of the subject.
        Returns:
        the canonical principal name
      • setPrincipalName

        @Nonnull
        public SubjectCanonicalizationContext setPrincipalName​(@Nullable
                                                               String name)
        Set the canonical principal name of the subject.
        Parameters:
        name - the canonical principal name
        Returns:
        this context
      • getException

        @Nullable
        public Exception getException()
        Get the exception raised by a failed canonicalization.
        Returns:
        exception raised by a failed canonicalization
      • setException

        @Nonnull
        public SubjectCanonicalizationContext setException​(@Nullable
                                                           Exception e)
        Set the exception raised by a failed canonicalization.
        Parameters:
        e - exception raised by a failed canonicalization
        Returns:
        this context
      • getRequesterId

        @Nullable
        public String getRequesterId()
        Get the requester's ID.
        Returns:
        the requester's ID
      • setRequesterId

        @Nonnull
        public SubjectCanonicalizationContext setRequesterId​(@Nullable
                                                             String id)
        Set the requester's ID.
        Parameters:
        id - the requester's ID
        Returns:
        this context
      • getResponderId

        @Nullable
        public String getResponderId()
        Get the responder's ID.
        Returns:
        the responder's ID
      • setResponderId

        @Nonnull
        public SubjectCanonicalizationContext setResponderId​(@Nullable
                                                             String id)
        Set the responder's ID.
        Parameters:
        id - the responder's ID
        Returns:
        this context
      • getAttemptedFlow

        @Nullable
        public SubjectCanonicalizationFlowDescriptor getAttemptedFlow()
        Get the last flow that was attempted for subject c14n.
        Returns:
        last flow that was attempted for subject c14n