v2ray-core/proxy/dokodemo/dokodemo_factory.go

19 lines
472 B
Go
Raw Normal View History

2015-10-30 14:56:46 +00:00
package dokodemo
import (
"github.com/v2ray/v2ray-core/app"
"github.com/v2ray/v2ray-core/proxy/common/connhandler"
)
type DokodemoDoorFactory struct {
}
2015-12-05 21:55:45 +00:00
func (this DokodemoDoorFactory) Create(space *app.Space, rawConfig interface{}) (connhandler.InboundConnectionHandler, error) {
2015-12-06 17:21:15 +00:00
config := rawConfig.(Config)
2015-12-05 21:55:45 +00:00
return NewDokodemoDoor(space, config), nil
2015-10-30 14:56:46 +00:00
}
func init() {
connhandler.RegisterInboundConnectionHandlerFactory("dokodemo-door", DokodemoDoorFactory{})
}