QBitRun/lib/workflow/context.go

25 lines
473 B
Go

package workflow
type Context struct {
TorrentName string
Category string
Tags []string
ContentPath string
RootPath string
SavePath string
NumberOfFiles int
TorrentSize uint64
CurrentTracker string
InfoHashV1 string
InfoHashV2 string
TorrentID string
AddEvent bool
}
func (c Context) AsMap() map[string]any {
return map[string]any{
"torrent_name": c.TorrentName,
"category": c.Category,
}
}