dae/component/outbound/dialer/direct.go

14 lines
427 B
Go
Raw Normal View History

2023-01-23 18:54:21 +07:00
package dialer
import (
softwindDirect "github.com/mzz2017/softwind/protocol/direct"
2023-01-23 18:54:21 +07:00
)
2023-01-28 00:50:21 +07:00
func NewDirectDialer(option *GlobalOption, fullcone bool) *Dialer {
2023-01-27 01:10:27 +07:00
if fullcone {
return NewDialer(softwindDirect.FullconeDirect, option, InstanceOption{CheckEnabled: false}, "direct", "direct", "")
2023-01-27 01:10:27 +07:00
} else {
return NewDialer(softwindDirect.SymmetricDirect, option, InstanceOption{CheckEnabled: false}, "direct", "direct", "")
2023-01-23 18:54:21 +07:00
}
}