config.go 305 B

12345678910111213141516171819
  1. package rules
  2. import (
  3. v2net "github.com/v2ray/v2ray-core/common/net"
  4. )
  5. type Rule struct {
  6. Tag string
  7. Condition Condition
  8. }
  9. func (this *Rule) Apply(dest v2net.Destination) bool {
  10. return this.Condition.Apply(dest)
  11. }
  12. type RouterRuleConfig struct {
  13. Rules []*Rule
  14. ResolveDomain bool
  15. }