| | |
| | | |
| | | public static bool TcpServerSend(string ip, byte[] msg) |
| | | { |
| | | LogHelper.Info($"TcpServerSend >{ip}:{msg}"); |
| | | if (clients.Keys.Contains(ip)) |
| | | { |
| | | var client = clients[ip]; |
| | |
| | | { |
| | | try |
| | | { |
| | | client.Send(msg); |
| | | client.Send(msg); |
| | | LogHelper.Info($"TcpServerSend > åéæåã"); |
| | | return true; |
| | | } |
| | | catch (SocketException ex) |
| | |
| | | // 转æ¢ååè¿å¶ |
| | | return Convert.ToInt32(new string(binaryChars), 2); |
| | | } |
| | | public static List<string> GetStaticClients() => clients.Keys.ToList(); |
| | | public static Dictionary<string, string> GetStaticScan() => TrayIps; |
| | | } |
| | | } |
| | | |