예제 #1
0
        private DataPackage SendAndRecieve(DataPackage p)
        {
            var socket = SocketPool.Rent(_options.Host, _options.Port);
            var res    = SocketPool.SendAndResieve(socket, p.ToArray());

            SocketPool.Return(socket);
            return(new DataPackage(res));
        }
예제 #2
0
 public void Dispose()
 {
     Disconnect();
     _clientAes?.Dispose();
     SocketPool.Clear();
 }