资源简介
下载此项目需要结合本人的博客去操作,博客地址,https://blog.csdn.net/qq_37602761/article/details/83587775

代码片段和文件信息
/**************************************************************************
**
** This file is part of QSsh
**
** Copyright (c) 2012 LVK
**
** Contact: andres.pagliano@lvklabs.com
**
** GNU Lesser General Public License Usage
**
** This file may be used under the terms of the GNU Lesser General Public
** License version 2.1 as published by the Free Software Foundation and
** appearing in the file LICENSE.LGPL included in the packaging of this file.
** Please review the following information to ensure the GNU Lesser General
** Public License version 2.1 requirements will be met:
** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
**
**************************************************************************/
#include
#include
#include
#include
#include
//#include “securefileuploader.h“
//void showSyntax();
//QString getPassword();
//void upload(const QString &orig const QString &dest const QString passwd);
int main(int argc char *argv[])
{
QCoreApplication a(argc argv);
// if (argc != 3) {
// showSyntax();
// }
// QString orig = argv[1];
// QString dest = argv[2];
// //QString passwd = getPassword();
// upload(orig dest “123456“);
SZRSFtpTools sftpClient;
sftpClient.setSftpInfo(“192.168.0.118““szsh““szsh123“);
// for (int i = 0 ; i < 1000;i++)
// {
// }
// QStringList downLoadFiles;
// downLoadFiles << “/home/xiao/1.txt“ << “/home/xiao/remote“;
//sftpClient.downLoadFile(“G:/GO““/home/xiao/1.txt“);
// sftpClient.downLoadFiles(“G:/GO“downLoadFiles);
QStringList upLoadFiles;
upLoadFiles << “G:/GO/1.txt“ << “G:/GO/remote“;
sftpClient.uploadFiles(“/home/szsh“upLoadFiles);
//sftpClient.uploadFile(“/home/xiao““G:/GO/1.txt“);
return a.exec();
}
/*void showSyntax()
{
std::cerr << “Syntax: “ << std::endl;
std::cerr << “ SecureUploader local_file username@host:/destination_path“ << std::endl;
exit(1);
}
QString getPassword()
{
std::cout << “Password (Warning password will be echoed): “;
std::string passwd;
std::cin >> passwd;
return QString::fromStdString(passwd).trimmed();
}
void upload(const QString &orig const QString &dest const QString passwd)
{
// Parse destination with format “username@host:/destination“
QStringList l1 = dest.split(“@“);
if (l1.size() == 2) {
QStringList l2 = l1[1].split(“:“);
if (l2.size() == 2) {
static SecureFileUploader uploader;
uploader.upload(orig l2[1] l2[0] l1[0] passwd);
} else {
std::cerr << “SecureUploader: Error invalid parameter “ << dest.toStdString() << std::endl;
showSyntax();
}
} else {
std::cerr << “SecureUploader: Error invalid parameter “ << dest.toStdString() << std::endl;
showSyntax();
}
}*/
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
....... 3329 2016-07-03 18:37 QSsh-master\.gitignore
文件 85 2018-10-29 12:13 QSsh-master\examples\examples.pro
文件 2922 2018-10-30 14:29 QSsh-master\examples\SecureUploader\main.cpp
文件 6892 2018-10-31 11:41 QSsh-master\examples\SecureUploader\securefileuploader.cpp
文件 2586 2018-10-31 11:41 QSsh-master\examples\SecureUploader\securefileuploader.h
文件 738 2018-10-31 11:36 QSsh-master\examples\SecureUploader\SecureUploader.pro
文件 1327 2018-10-31 11:50 QSsh-master\examples\SecureUploader\SZRSFtpTools.cpp
文件 1075 2018-10-31 11:50 QSsh-master\examples\SecureUploader\SZRSFtpTools.h
....... 59 2016-07-03 18:37 QSsh-master\examples\ssh\errorhandling\errorhandling.pro
....... 7352 2016-07-03 18:37 QSsh-master\examples\ssh\errorhandling\main.cpp
....... 6486 2016-07-03 18:37 QSsh-master\examples\ssh\remoteprocess\argumentscollector.cpp
....... 1990 2016-07-03 18:37 QSsh-master\examples\ssh\remoteprocess\argumentscollector.h
....... 1777 2016-07-03 18:37 QSsh-master\examples\ssh\remoteprocess\main.cpp
....... 153 2016-07-03 18:37 QSsh-master\examples\ssh\remoteprocess\remoteprocess.pro
....... 12830 2016-07-03 18:37 QSsh-master\examples\ssh\remoteprocess\remoteprocesstest.cpp
....... 2647 2016-07-03 18:37 QSsh-master\examples\ssh\remoteprocess\remoteprocesstest.h
....... 6769 2016-07-03 18:37 QSsh-master\examples\ssh\sftp\argumentscollector.cpp
....... 1972 2016-07-03 18:37 QSsh-master\examples\ssh\sftp\argumentscollector.h
文件 1776 2018-10-29 16:01 QSsh-master\examples\ssh\sftp\main.cpp
....... 1406 2016-07-03 18:37 QSsh-master\examples\ssh\sftp\parameters.h
....... 146 2016-07-03 18:37 QSsh-master\examples\ssh\sftp\sftp.pro
....... 24930 2016-07-03 18:37 QSsh-master\examples\ssh\sftp\sftptest.cpp
....... 3901 2016-07-03 18:37 QSsh-master\examples\ssh\sftp\sftptest.h
....... 1458 2016-07-03 18:37 QSsh-master\examples\ssh\sftpfsmodel\main.cpp
....... 174 2016-07-03 18:37 QSsh-master\examples\ssh\sftpfsmodel\sftpfsmodel.pro
....... 4246 2016-07-03 18:37 QSsh-master\examples\ssh\sftpfsmodel\window.cpp
....... 1828 2016-07-03 18:37 QSsh-master\examples\ssh\sftpfsmodel\window.h
....... 5728 2016-07-03 18:37 QSsh-master\examples\ssh\sftpfsmodel\window.ui
....... 1746 2016-07-03 18:37 QSsh-master\examples\ssh\shell\main.cpp
....... 3691 2016-07-03 18:37 QSsh-master\examples\ssh\shell\shell.cpp
............此处省略141个文件信息
相关资源
- mgn-mqt82.exe
- Trojan-Qt5-Windows-0.0.4.rar
- 酒店管理系统基于Qt Creator5)
- vtk QT做的三维地质可视化系统2of2
- Qt局域网聊天软件
- Qt Creator opengl实现四元数鼠标控制轨迹
- QT局域网聊天系统(基于QT5.修改过)
- qt-电子点菜系统
- C 餐厅叫号系统(QT平)
- QT 实现文件下载
- qt图像处理
- QT,JPEG解码源代码(已完成)
- Qt 播放音频文件
- Qt 读取16进制的data文件
- MQTT+串口(usart)透传
- 易语言QQTEA算法源码
- VC工程转Qt工程文件的工具
- MQTT推送Demo
- 基于Linux、QT的视频监控系统的设计与
- Qt 百度地图 定位
- QT酷炫界面开发指南《QmlBook》
- Ubuntu下操作Excel,qt代码
- PSFTP.EXE 工具
- Qt图片浏览器 --基于Qt的Graphics View f
- qtnribbon2破解
- Qt软件开发 完整项目代码
- MQTT_3.1protocol_Specific中文版
- 在QT中使用RTP进行视频的采集和传输
- Mini6410 Qt4和Qtopia编程开发指南
- Qt实现Code39条形码
评论
共有 条评论