Documentation ¶
Index ¶
- Constants
- func DisableLog()
- func UseLogger(logger slog.Logger)
- type EventAuthorize
- type EventStart
- type TicketVote
- func (t *TicketVote) HandleAuthorize(w http.ResponseWriter, r *http.Request)
- func (t *TicketVote) HandleCastBallot(w http.ResponseWriter, r *http.Request)
- func (t *TicketVote) HandleDetails(w http.ResponseWriter, r *http.Request)
- func (t *TicketVote) HandleInventory(w http.ResponseWriter, r *http.Request)
- func (t *TicketVote) HandlePolicy(w http.ResponseWriter, r *http.Request)
- func (t *TicketVote) HandleResults(w http.ResponseWriter, r *http.Request)
- func (t *TicketVote) HandleStart(w http.ResponseWriter, r *http.Request)
- func (t *TicketVote) HandleSubmissions(w http.ResponseWriter, r *http.Request)
- func (t *TicketVote) HandleSummaries(w http.ResponseWriter, r *http.Request)
- func (t *TicketVote) HandleTimestamps(w http.ResponseWriter, r *http.Request)
Constants ¶
const ( // EventTypeAuthorize is emitted when a vote is authorized. EventTypeAuthorize = "ticketvote-authorize" // EventTypeStart is emitted when a vote is started. EventTypeStart = "ticketvote-start" )
Variables ¶
This section is empty.
Functions ¶
func DisableLog ¶
func DisableLog()
DisableLog disables all library log output. Logging output is disabled by default until either UseLogger or SetLogWriter are called.
Types ¶
type EventAuthorize ¶
EventAuthorize is the event data for EventTypeAuthorize.
type EventStart ¶
type EventStart struct { Starts []v1.StartDetails User user.User }
EventStart is the event data for EventTypeStart.
type TicketVote ¶
type TicketVote struct {
// contains filtered or unexported fields
}
TicketVote is the context for the ticketvote API.
func New ¶
func New(cfg *config.Config, pdc *pdclient.Client, s *sessions.Sessions, e *events.Manager, plugins []pdv2.Plugin) (*TicketVote, error)
New returns a new TicketVote context.
func (*TicketVote) HandleAuthorize ¶
func (t *TicketVote) HandleAuthorize(w http.ResponseWriter, r *http.Request)
HandleAuthorize is the request handler for the ticketvote v1 Authorize route.
func (*TicketVote) HandleCastBallot ¶
func (t *TicketVote) HandleCastBallot(w http.ResponseWriter, r *http.Request)
HandleCastBallot is the request handler for the ticketvote v1 CastBallot route.
func (*TicketVote) HandleDetails ¶
func (t *TicketVote) HandleDetails(w http.ResponseWriter, r *http.Request)
HandleDetails is the request handler for the ticketvote v1 Details route.
func (*TicketVote) HandleInventory ¶
func (t *TicketVote) HandleInventory(w http.ResponseWriter, r *http.Request)
HandleInventory is the request handler for the ticketvote v1 Inventory route.
func (*TicketVote) HandlePolicy ¶
func (t *TicketVote) HandlePolicy(w http.ResponseWriter, r *http.Request)
HandlePolicy is the request handler for the ticketvote v1 Policy route.
func (*TicketVote) HandleResults ¶
func (t *TicketVote) HandleResults(w http.ResponseWriter, r *http.Request)
HandleResults is the request handler for the ticketvote v1 Results route.
func (*TicketVote) HandleStart ¶
func (t *TicketVote) HandleStart(w http.ResponseWriter, r *http.Request)
HandleStart is the requeset handler for the ticketvote v1 Start route.
func (*TicketVote) HandleSubmissions ¶
func (t *TicketVote) HandleSubmissions(w http.ResponseWriter, r *http.Request)
HandleSubmissions is the request handler for the ticketvote v1 Submissions route.
func (*TicketVote) HandleSummaries ¶
func (t *TicketVote) HandleSummaries(w http.ResponseWriter, r *http.Request)
HandleSummaries is the request handler for the ticketvote v1 Summaries route.
func (*TicketVote) HandleTimestamps ¶
func (t *TicketVote) HandleTimestamps(w http.ResponseWriter, r *http.Request)
HandleTimestamps is the request handler for the ticketvote v1 Timestamps route.