本文整理匯總了Java中org.apache.commons.vfs2.provider.ftp.FtpFileProvider類的典型用法代碼示例。如果您正苦於以下問題:Java FtpFileProvider類的具體用法?Java FtpFileProvider怎麽用?Java FtpFileProvider使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。
FtpFileProvider類屬於org.apache.commons.vfs2.provider.ftp包,在下文中一共展示了FtpFileProvider類的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: addProviders
import org.apache.commons.vfs2.provider.ftp.FtpFileProvider; //導入依賴的package包/類
protected void addProviders(DefaultFileSystemManager manager) throws FileSystemException {
manager.addProvider("tmp", new TemporaryFileProvider());
manager.addProvider("res", new ResourceFileProvider());
manager.addProvider("ram", new RamFileProvider());
manager.addProvider("zip", new ZipFileProvider());
manager.addProvider("jar", new JarFileProvider());
manager.addProvider("tar", new TarFileProvider());
manager.addProvider("tgz", new TgzFileProvider());
manager.addProvider("tbz2", new Tbz2FileProvider());
manager.addProvider("gz", new GzipFileProvider());
manager.addProvider("bz2", new Bzip2FileProvider());
manager.addProvider("http", new HttpFileProvider());
manager.addProvider("https", new HttpsFileProvider());
manager.addProvider("webdav", new WebdavFileProvider());
manager.addProvider("ftp", new FtpFileProvider());
manager.addProvider("ftps", new FtpsFileProvider());
}
示例2: getManager
import org.apache.commons.vfs2.provider.ftp.FtpFileProvider; //導入依賴的package包/類
public static DefaultFileSystemManager getManager() throws FileSystemException {
DefaultFileSystemManager mngr = new DefaultFileSystemManager();
mngr.addProvider("sftp", new SftpFileProvider());
mngr.addProvider("ftp", new FtpFileProvider());
mngr.addProvider("file", new DefaultLocalFileProvider());
mngr.init();
return mngr;
}
示例3: prepare
import org.apache.commons.vfs2.provider.ftp.FtpFileProvider; //導入依賴的package包/類
/**
* Prepares the file system manager.
*/
@Override
public void prepare(final DefaultFileSystemManager manager) throws Exception
{
manager.addProvider("ftp", new FtpFileProvider());
}