Exemplo n.º 1
0
 public void send(HttpRequest request) throws InterruptedException {
   if (channel != null) {
     ChannelFuture future = channel.writeAndFlush(request).sync();
   } else {
     System.out.println("消息发送失败,连接尚未建立!");
   }
 }