java.io.IOException: Attempted read on closed stream.

  • Post author:
  • Post category:java



java.io.IOException: Attempted read on closed stream.


尝试读取关闭流。


出现这种情况,一个原因可能是 把客户端与服务端的连接对象关闭了 或是 清空了。


ServiceClient sender = getSender();

sender.setOptions(webTest.buildOptions(“getCarsList”));

OMElement result = sender.sendReceive(webTest.buildParam(“getCarsList”));


// sender.cleanupTransport();

return result.toString();



版权声明:本文为competerH_programing原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。