mirror of
https://github.com/eolinker/apinto
synced 2025-10-09 18:50:34 +08:00
DubboCtx,grpcCtx,WebSocketCtx,补充IsCloneable,Clone方法,
This commit is contained in:
@@ -3,6 +3,7 @@ package http_context
|
||||
import (
|
||||
"errors"
|
||||
"fmt"
|
||||
eoscContext "github.com/eolinker/eosc/eocontext"
|
||||
"io"
|
||||
"net"
|
||||
"sync"
|
||||
@@ -79,3 +80,15 @@ func (w *WebsocketContext) Assert(i interface{}) error {
|
||||
}
|
||||
return fmt.Errorf("not suport:%s", config.TypeNameOf(i))
|
||||
}
|
||||
|
||||
func (w *WebsocketContext) IsCloneable() bool {
|
||||
return false
|
||||
}
|
||||
|
||||
func (w *WebsocketContext) Clone() (eoscContext.EoContext, error) {
|
||||
if !w.IsCloneable() {
|
||||
return nil, fmt.Errorf("%s %w", "WebsocketContext", eoscContext.ErrEoCtxUnCloneable)
|
||||
}
|
||||
//TODO
|
||||
return nil, nil
|
||||
}
|
||||
|
Reference in New Issue
Block a user