MCPcopy
hub / github.com/yusing/godoxy / TCPTCPStream

Struct TCPTCPStream

internal/route/stream/tcp_tcp.go:18–34  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

16)
17
18type TCPTCPStream struct {
19 listener net.Listener
20
21 network string
22 dstNetwork string
23
24 laddr *net.TCPAddr
25 dst *net.TCPAddr
26 agent *agentpool.Agent
27
28 relayProxyProtocolHeader bool
29
30 preDial nettypes.HookFunc
31 onRead nettypes.HookFunc
32
33 closed atomic.Bool
34}
35
36func NewTCPTCPStream(network, dstNetwork, listenAddr, dstAddr string, agent *agentpool.Agent, relayProxyProtocolHeader bool) (nettypes.Stream, error) {
37 dst, err := net.ResolveTCPAddr(dstNetwork, dstAddr)

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected