com.jcraft.jsch.Channel.close()方法的使用及代码示例

x33g5p2x  于2022-01-18 转载在 其他  
字(2.1k)|赞(0)|评价(0)|浏览(137)

本文整理了Java中com.jcraft.jsch.Channel.close()方法的一些代码示例,展示了Channel.close()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Channel.close()方法的具体详情如下:
包路径:com.jcraft.jsch.Channel
类名称:Channel
方法名:close

Channel.close介绍

暂无

代码示例

代码示例来源:origin: org.xbib/jsch-core

public void disconnect() {
  try {
    synchronized (this) {
      if (!connected) {
        return;
      }
      connected = false;
    }
    close();
    eof_remote = eof_local = true;
    thread = null;
    try {
      if (io != null) {
        io.close();
      }
    } catch (Exception e) {
      logger.log(Level.SEVERE, e.getMessage(), e);
    }
  } finally {
    Channel.del(this);
  }
}

代码示例来源:origin: com.jcraft.jsch/com.springsource.com.jcraft.jsch

public void disconnect(){
 //System.err.println(this+":disconnect "+io+" "+connected);
 //Thread.dumpStack();
 synchronized(this){
  if(!connected){
   return;
  }
  connected=false;
 }
 close();
 eof_remote=eof_local=true;
 thread=null;
 try{
  if(io!=null){
   io.close();
  }
 }
 catch(Exception e){
  //e.printStackTrace();
 }
 io=null;
 Channel.del(this);
}

代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.jsch

public void disconnect(){
 //System.err.println(this+":disconnect "+io+" "+connected);
 //Thread.dumpStack();
 try{
  synchronized(this){
   if(!connected){
    return;
   }
   connected=false;
  }
  close();
  eof_remote=eof_local=true;
  thread=null;
  try{
   if(io!=null){
    io.close();
   }
  }
  catch(Exception e){
   //e.printStackTrace();
  }
  // io=null;
 }
 finally{
  Channel.del(this);
 }
}

代码示例来源:origin: org.mule.jsch/jsch

public void disconnect(){
 //System.err.println(this+":disconnect "+io+" "+connected);
 //Thread.dumpStack();
 try{
  synchronized(this){
   if(!connected){
    return;
   }
   connected=false;
  }
  close();
  eof_remote=eof_local=true;
  thread=null;
  try{
   if(io!=null){
    io.close();
   }
  }
  catch(Exception e){
   //e.printStackTrace();
  }
  // io=null;
 }
 finally{
  Channel.del(this);
 }
}

代码示例来源:origin: ePaul/jsch-documentation

/**
 * disconnects this channel.
 */
public void disconnect(){
 //System.err.println(this+":disconnect "+io+" "+connected);
 //Thread.dumpStack();
 try{
  synchronized(this){
   if(!connected){
    return;
   }
   connected=false;
  }
  close();
  eof_remote=eof_local=true;
  thread=null;
  try{
   if(io!=null){
    io.close();
   }
  }
  catch(Exception e){
   //e.printStackTrace();
  }
  // io=null;
 }
 finally{
  Channel.del(this);
 }
}

相关文章