Need to transfer ear file from unix server to local machine using java
<p>I am trying to transfer ear file from Unix server to local machine. But I am not able to get the ear . I am using :</p>

<pre><code>JSch jsch = new JSch(); 
Session session = null; 
try { 
    session = jsch.getSession("user", "10.213.31.123", 22); 
    session.setConfig("StrictHostKeyChecking", "no"); 
    session.setPassword("pwd"); 
    session.connect(); 
    Channel channel = session.openChannel("sftp"); 
    channel.connect(); 
    ChannelSftp sftpChannel = (ChannelSftp) channel; 
    sftpChannel.get("/osszone/cramer/users/xpi012/JEE/tsrpwl7/WLS/tsrpwl7/servers/CramerServer/stage/CramerServer_CramerAPI/CramerAPI.ear", "C:/sftp"); 
    sftpChannel.exit(); 
    session.disconnect(); 
} catch (JSchException e) { 
    e.printStackTrace();  
} catch (SftpException e) { 
    e.printStackTrace(); 
} 
</code></pre>
