This commit is contained in:
MetaCubeX
2022-03-17 23:24:07 +08:00
parent 30f1b29257
commit 435bee0ca2
37 changed files with 329 additions and 727 deletions

View File

@ -1,8 +1,12 @@
package logic
import C "github.com/Dreamacro/clash/constant"
import (
C "github.com/Dreamacro/clash/constant"
"github.com/Dreamacro/clash/rule/common"
)
type OR struct {
common.Base
rules []C.Rule
payload string
adapter string
@ -39,10 +43,6 @@ func (or *OR) ShouldResolveIP() bool {
return or.needIP
}
func (or *OR) RuleExtra() *C.RuleExtra {
return nil
}
func NewOR(payload string, adapter string) (*OR, error) {
or := &OR{payload: payload, adapter: adapter}
rules, err := parseRuleByPayload(payload)