Topic: JAVA中如何执行FTP命令? |
Print this page |
1.JAVA中如何执行FTP命令? | Copy to clipboard |
Posted by: wangfeng7838 Posted on: 2004-11-23 13:20 请问高手,如何在JAVA中执行FTP协议中的命令?急,谢了先! |
2.Re:JAVA中如何执行FTP命令? [Re: wangfeng7838] | Copy to clipboard |
Posted by: wangfeng7838 Posted on: 2004-11-23 13:21 |
3.Re:JAVA中如何执行FTP命令? [Re: wangfeng7838] | Copy to clipboard |
Posted by: Jove Posted on: 2004-11-23 13:39 了解FTP协议,直接操作套接字 或找个现成lib,如 http://jakarta.apache.org/commons/net/ |
4.Re:JAVA中如何执行FTP命令? [Re: wangfeng7838] | Copy to clipboard |
Posted by: jameszhang Posted on: 2004-11-23 15:27 sun.net.ftp.FtpClient |
5.Re:JAVA中如何执行FTP命令? [Re: wangfeng7838] | Copy to clipboard |
Posted by: Lawme Posted on: 2004-11-23 16:53 Java FTP 的关键是建立 URL 时的语法。本例中是这句: URL url = new URL(args[1]); 这里的 args[1] 结构必须为: ftp:// user : password @ FtpUrl 例如: ftp://someone:m3j4v8@dongfang.com/pages/index.html 以下是段 FTP 上传文件的代码:
|
Powered by Jute Powerful Forum® Version Jute 1.5.6 Ent Copyright © 2002-2021 Cjsdn Team. All Righits Reserved. 闽ICP备05005120号-1 客服电话 18559299278 客服信箱 714923@qq.com 客服QQ 714923 |