Interface ConfirmationContext<C>

Type Parameters:
C - command sender type

@Immutable @API(status=STABLE, since="1.0.0") public interface ConfirmationContext<C>
Context that stores information about a pending confirmation.
Since:
1.0.0
  • Method Details

    • of

      static <C> @NonNull ConfirmationContext<C> of(@NonNull Instant creationTime, @NonNull Command<C> command, @NonNull CommandContext<C> commandContext)
      Creates a new confirmation context.
      Type Parameters:
      C - command sender type
      Parameters:
      creationTime - time of creation
      command - command that requires confirmation
      commandContext - command context that requires confirmation
      Returns:
      the created context
    • creationTime

      @NonNull Instant creationTime()
      Returns the time the context was created.
      Returns:
      the creation time
    • command

      @NonNull Command<C> command()
      Returns the command that requires confirmation.
      Returns:
      the command
    • commandContext

      @NonNull CommandContext<C> commandContext()
      Returns the execution context that required confirmation.
      Returns:
      the command context