events

package
v0.0.0-...-e487a75 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 11, 2025 License: Apache-2.0 Imports: 7 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type EventParser

type EventParser struct{}

EventParser 事件解析器

func NewEventParser

func NewEventParser() *EventParser

NewEventParser 创建新的事件解析器

func (*EventParser) ParseEvent

func (p *EventParser) ParseEvent(ctx context.Context, eventType string, rawEvent interface{}) (models.GitHubContext, error)

ParseEvent 解析通用事件(兼容性方法)

func (*EventParser) ParseIssueCommentEvent

func (p *EventParser) ParseIssueCommentEvent(ctx context.Context, event *github.IssueCommentEvent) (models.GitHubContext, error)

ParseIssueCommentEvent 解析Issue评论事件(从原始GitHub事件)

func (*EventParser) ParseWebhookEvent

func (p *EventParser) ParseWebhookEvent(
	ctx context.Context,
	eventType string,
	deliveryID string,
	payload []byte,
) (models.GitHubContext, error)

ParseWebhookEvent 解析webhook事件为统一的GitHubContext

type Parser

type Parser = EventParser

Parser 事件解析器接口(向前兼容)

func NewParser

func NewParser() *Parser

NewParser 创建新的事件解析器(向前兼容)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL