RawIP 原本IP
()
| 134 | |
| 135 | // RawIP 原本IP |
| 136 | func (this *BaseClientConn) RawIP() string { |
| 137 | if len(this.rawIP) > 0 { |
| 138 | return this.rawIP |
| 139 | } |
| 140 | |
| 141 | ip, _, _ := net.SplitHostPort(this.rawConn.RemoteAddr().String()) |
| 142 | this.rawIP = ip |
| 143 | return ip |
| 144 | } |
| 145 | |
| 146 | // TCPConn 转换为TCPConn |
| 147 | func (this *BaseClientConn) TCPConn() (tcpConn *net.TCPConn, ok bool) { |
no test coverage detected