mirror of
https://github.com/labstack/echo.git
synced 2025-03-27 21:48:57 +02:00
removed websocket api
Signed-off-by: Vishal Rana <vr@labstack.com>
This commit is contained in:
parent
093e5c9ed6
commit
51723e4c7c
19
context.go
19
context.go
@ -1,6 +1,7 @@
|
|||||||
package echo
|
package echo
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"bytes"
|
||||||
"encoding/json"
|
"encoding/json"
|
||||||
"encoding/xml"
|
"encoding/xml"
|
||||||
"fmt"
|
"fmt"
|
||||||
@ -16,8 +17,6 @@ import (
|
|||||||
"time"
|
"time"
|
||||||
|
|
||||||
"golang.org/x/net/websocket"
|
"golang.org/x/net/websocket"
|
||||||
|
|
||||||
"bytes"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type (
|
type (
|
||||||
@ -27,18 +26,12 @@ type (
|
|||||||
// Request returns `*http.Request`.
|
// Request returns `*http.Request`.
|
||||||
Request() *http.Request
|
Request() *http.Request
|
||||||
|
|
||||||
// SetWebSocket sets `*http.Request`.
|
// SetRequest sets `*http.Request`.
|
||||||
SetRequest(*http.Request)
|
SetRequest(*http.Request)
|
||||||
|
|
||||||
// Request returns `*Response`.
|
// Request returns `*Response`.
|
||||||
Response() *Response
|
Response() *Response
|
||||||
|
|
||||||
// WebSocket returns `*websocket.Conn`.
|
|
||||||
WebSocket() *websocket.Conn
|
|
||||||
|
|
||||||
// SetWebSocket sets `*websocket.Conn`.
|
|
||||||
SetWebSocket(*websocket.Conn)
|
|
||||||
|
|
||||||
// IsTLS returns true if HTTP connection is TLS otherwise false.
|
// IsTLS returns true if HTTP connection is TLS otherwise false.
|
||||||
IsTLS() bool
|
IsTLS() bool
|
||||||
|
|
||||||
@ -220,14 +213,6 @@ func (c *context) Response() *Response {
|
|||||||
return c.response
|
return c.response
|
||||||
}
|
}
|
||||||
|
|
||||||
func (c *context) WebSocket() *websocket.Conn {
|
|
||||||
return c.webSocket
|
|
||||||
}
|
|
||||||
|
|
||||||
func (c *context) SetWebSocket(ws *websocket.Conn) {
|
|
||||||
c.webSocket = ws
|
|
||||||
}
|
|
||||||
|
|
||||||
func (c *context) IsTLS() bool {
|
func (c *context) IsTLS() bool {
|
||||||
return c.request.TLS != nil
|
return c.request.TLS != nil
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user