rename InboundConnectionHandler to InboundHandler

This commit is contained in:
v2ray
2016-01-25 17:18:24 +01:00
parent 4817f8ab1f
commit 9fe8178e4a
21 changed files with 37 additions and 37 deletions
+1 -1
View File
@@ -175,7 +175,7 @@ func handleOutput(request *protocol.VMessRequest, writer io.Writer, output <-cha
func init() {
internal.MustRegisterInboundConnectionHandlerCreator("vmess",
func(space app.Space, rawConfig interface{}) (proxy.InboundConnectionHandler, error) {
func(space app.Space, rawConfig interface{}) (proxy.InboundHandler, error) {
config := rawConfig.(*Config)
allowedClients := protocol.NewTimedUserSet()
+1 -1
View File
@@ -191,7 +191,7 @@ func (this *VMessOutboundHandler) handleResponse(conn net.Conn, request *protoco
func init() {
internal.MustRegisterOutboundConnectionHandlerCreator("vmess",
func(space app.Space, rawConfig interface{}) (proxy.OutboundConnectionHandler, error) {
func(space app.Space, rawConfig interface{}) (proxy.OutboundHandler, error) {
vOutConfig := rawConfig.(*Config)
return &VMessOutboundHandler{
space: space,
+2 -2
View File
@@ -37,7 +37,7 @@ func TestVMessInAndOut(t *testing.T) {
ConnOutput: ichConnOutput,
}
protocol, err := proxytesting.RegisterInboundConnectionHandlerCreator("mock_och", func(space app.Space, config interface{}) (proxy.InboundConnectionHandler, error) {
protocol, err := proxytesting.RegisterInboundConnectionHandlerCreator("mock_och", func(space app.Space, config interface{}) (proxy.InboundHandler, error) {
ich.Space = space
return ich, nil
})
@@ -78,7 +78,7 @@ func TestVMessInAndOut(t *testing.T) {
ConnOutput: ochConnOutput,
}
protocol, err = proxytesting.RegisterOutboundConnectionHandlerCreator("mock_och", func(space app.Space, config interface{}) (proxy.OutboundConnectionHandler, error) {
protocol, err = proxytesting.RegisterOutboundConnectionHandlerCreator("mock_och", func(space app.Space, config interface{}) (proxy.OutboundHandler, error) {
return och, nil
})
assert.Error(err).IsNil()