Documentation ¶
Index ¶
- func HandleLogin(w http.ResponseWriter, r *http.Request)
- func HandleLogout(w http.ResponseWriter, r *http.Request)
- func HandlePublishConfirmationEmails(w http.ResponseWriter, r *http.Request)
- func HandleReSendConfirmationEmail(w http.ResponseWriter, r *http.Request)
- func HandleRegistration(w http.ResponseWriter, r *http.Request)
- func HandleVerifyRegistration(w http.ResponseWriter, r *http.Request)
- type EmailConfiguration
- type LoginCommand
- type LoginCommandHandler
- type ProcessActivationCodesCommand
- type ProcessActivationCodesCommandHandler
- type ReSendActivationEmailCommand
- type ReSendActivationEmailCommandHandler
- type RegisterCommand
- type RegisterCommandHandler
- type VerifyRegistrationCommand
- type VerifyRegistrationCommandHandler
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func HandleLogin ¶
func HandleLogin(w http.ResponseWriter, r *http.Request)
func HandleLogout ¶
func HandleLogout(w http.ResponseWriter, r *http.Request)
func HandlePublishConfirmationEmails ¶
func HandlePublishConfirmationEmails(w http.ResponseWriter, r *http.Request)
func HandleReSendConfirmationEmail ¶
func HandleReSendConfirmationEmail(w http.ResponseWriter, r *http.Request)
func HandleRegistration ¶
func HandleRegistration(w http.ResponseWriter, r *http.Request)
func HandleVerifyRegistration ¶
func HandleVerifyRegistration(w http.ResponseWriter, r *http.Request)
Types ¶
type EmailConfiguration ¶
type EmailConfiguration struct {
Sender string
}
type LoginCommand ¶
func (LoginCommand) Validate ¶
func (c LoginCommand) Validate() error
type LoginCommandHandler ¶
type LoginCommandHandler struct {
// contains filtered or unexported fields
}
func NewLoginCommandHandler ¶
func NewLoginCommandHandler(db *sql.DB, passwordHasher domain.PasswordHasher) *LoginCommandHandler
func (*LoginCommandHandler) Handle ¶
func (h *LoginCommandHandler) Handle(ctx context.Context, request LoginCommand) (domain.Session, error)
type ProcessActivationCodesCommand ¶
type ProcessActivationCodesCommand struct{}
type ProcessActivationCodesCommandHandler ¶
type ProcessActivationCodesCommandHandler struct {
// contains filtered or unexported fields
}
func NewProcessActivationCodesCommandHandler ¶
func NewProcessActivationCodesCommandHandler( db *sql.DB, emailClient *core.EmailClient, emailConfig EmailConfiguration, ) *ProcessActivationCodesCommandHandler
func (*ProcessActivationCodesCommandHandler) Handle ¶
func (h *ProcessActivationCodesCommandHandler) Handle( ctx context.Context, _ ProcessActivationCodesCommand, ) (core.Unit, error)
type ReSendActivationEmailCommand ¶
func (ReSendActivationEmailCommand) Validate ¶
func (c ReSendActivationEmailCommand) Validate() error
type ReSendActivationEmailCommandHandler ¶
type ReSendActivationEmailCommandHandler struct {
// contains filtered or unexported fields
}
func NewReSendActivationEmailCommandHandler ¶
func NewReSendActivationEmailCommandHandler( db *sql.DB, emailClient *core.EmailClient, emailSender string, ) *ReSendActivationEmailCommandHandler
func (ReSendActivationEmailCommandHandler) Handle ¶
func (h ReSendActivationEmailCommandHandler) Handle( ctx context.Context, request ReSendActivationEmailCommand, ) (core.Unit, error)
type RegisterCommand ¶
type RegisterCommand struct { Username string `json:"username"` Password string `json:"password"` Email string `json:"email"` }
func (RegisterCommand) Validate ¶
func (c RegisterCommand) Validate() error
type RegisterCommandHandler ¶
type RegisterCommandHandler struct {
// contains filtered or unexported fields
}
func NewRegisterCommandHandler ¶
func NewRegisterCommandHandler(db *sql.DB, passwordHasher domain.PasswordHasher) *RegisterCommandHandler
func (*RegisterCommandHandler) Handle ¶
func (h *RegisterCommandHandler) Handle(ctx context.Context, request RegisterCommand) (core.Unit, error)
type VerifyRegistrationCommand ¶
type VerifyRegistrationCommand struct {
Token string `json:"token"`
}
func (VerifyRegistrationCommand) Validate ¶
func (c VerifyRegistrationCommand) Validate() error
type VerifyRegistrationCommandHandler ¶
type VerifyRegistrationCommandHandler struct {
// contains filtered or unexported fields
}
func NewVerifyRegistrationCommandHandler ¶
func NewVerifyRegistrationCommandHandler(db *sql.DB) *VerifyRegistrationCommandHandler
func (*VerifyRegistrationCommandHandler) Handle ¶
func (h *VerifyRegistrationCommandHandler) Handle( ctx context.Context, request VerifyRegistrationCommand, ) (core.Unit, error)
Click to show internal directories.
Click to hide internal directories.