[build test]

This commit is contained in:
MetaCubeX
2022-03-16 00:43:08 +08:00
parent f01ac69654
commit 1034780e8e
15 changed files with 70 additions and 25 deletions

View File

@ -16,9 +16,14 @@ var processCache = cache.NewLRUCache(cache.WithAge(2), cache.WithSize(64))
type Process struct {
adapter string
process string
nameOnly bool
ruleExtra *C.RuleExtra
}
func (ps *Process) ShouldFindProcess() bool {
return false
}
func (ps *Process) RuleType() C.RuleType {
return C.Process
}
@ -70,10 +75,11 @@ func (ps *Process) RuleExtra() *C.RuleExtra {
return ps.ruleExtra
}
func NewProcess(process string, adapter string, ruleExtra *C.RuleExtra) (*Process, error) {
func NewProcess(process string, adapter string, nameOnly bool, ruleExtra *C.RuleExtra) (*Process, error) {
return &Process{
adapter: adapter,
process: process,
nameOnly: nameOnly,
ruleExtra: ruleExtra,
}, nil
}