MCPcopy
hub / github.com/wavetermdev/waveterm / GetConnNameFromContext

Function GetConnNameFromContext

pkg/remote/connparse/connparse.go:85–91  ·  view source on GitHub ↗
(ctx context.Context)

Source from the content-addressed store, hash-verified

83}
84
85func GetConnNameFromContext(ctx context.Context) (string, error) {
86 handler := wshutil.GetRpcResponseHandlerFromContext(ctx)
87 if handler == nil {
88 return "", fmt.Errorf("error getting rpc response handler from context")
89 }
90 return handler.GetRpcContext().Conn, nil
91}
92
93// ParseURI parses a connection URI and returns the connection type, host/path, and parameters.
94func ParseURI(uri string) (*Connection, error) {

Callers 1

Calls 2

GetRpcContextMethod · 0.45

Tested by

no test coverage detected