This commit is contained in:
crusader 2017-11-30 15:11:11 +09:00
parent de7d112428
commit 3ed8b99ddd

View File

@ -6,7 +6,6 @@ import (
"git.loafle.net/commons_go/logging"
"git.loafle.net/commons_go/rpc/client"
"git.loafle.net/commons_go/rpc/protocol"
cwf "git.loafle.net/commons_go/websocket_fasthttp"
cwfc "git.loafle.net/commons_go/websocket_fasthttp/client"
)
@ -28,7 +27,7 @@ func (crwch *ClientReadWriteCloseHandlers) Connect(clientCTX client.ClientContex
}
func (crwch *ClientReadWriteCloseHandlers) ReadResponse(clientCTX client.ClientContext, codec protocol.ClientCodec, conn interface{}) (protocol.ClientResponseCodec, error) {
soc := conn.(cwf.Socket)
soc := conn.(cwfc.Socket)
_, r, err := soc.NextReader()
resCodec, err := codec.NewResponse(r)
@ -37,7 +36,7 @@ func (crwch *ClientReadWriteCloseHandlers) ReadResponse(clientCTX client.ClientC
}
func (crwch *ClientReadWriteCloseHandlers) WriteRequest(clientCTX client.ClientContext, codec protocol.ClientCodec, conn interface{}, method string, params interface{}, id interface{}) error {
soc := conn.(cwf.Socket)
soc := conn.(cwfc.Socket)
wc, wErr := soc.NextWriter(websocket.TextMessage)
if nil != wErr {
@ -55,7 +54,7 @@ func (crwch *ClientReadWriteCloseHandlers) WriteRequest(clientCTX client.ClientC
}
func (crwch *ClientReadWriteCloseHandlers) Disconnect(clientCTX client.ClientContext, conn interface{}) {
soc := conn.(cwf.Socket)
soc := conn.(cwfc.Socket)
soc.Close()
}