上一页 1 ··· 8 9 10 11 12 13 下一页
摘要: ui->tableWidget->setSelectionBehavior(QAbstractItemView::SelectRows);//选中一行 ui->tableWidget->setSelectionMode(QAbstractItemView::ExtendedSelection);// 阅读全文
posted @ 2021-07-17 22:02 Azuki_op 阅读(277) 评论(0) 推荐(0)
摘要: 函数原型 bool QObject::inherits ( const char * lname ) const //来自官方文档 QTimer *timer = new QTimer; // QTimer inherits QObject timer->inherits("QTimer"); // 阅读全文
posted @ 2021-07-16 01:41 Azuki_op 阅读(1039) 评论(0) 推荐(0)
摘要: 安装crontab: yum install crontabs crontab服务操作说明: /sbin/service crond start //启动服务 /sbin/service crond stop //关闭服务 /sbin/service crond restart //重启服务 /sb 阅读全文
posted @ 2021-07-16 01:29 Azuki_op 阅读(76) 评论(0) 推荐(0)
摘要: #include <QtXml> private: const QString CONFIG_PATH = "./config.xml"; const QString UDP_STR = "udp"; const QString TCP_STR = "tcp"; const QString SQL_ 阅读全文
posted @ 2021-07-16 01:14 Azuki_op 阅读(69) 评论(0) 推荐(0)
摘要: 单例模式:: 只实例化一次对象 分为饿汉式单例类和懒汉式单例类。 一般结合工厂模式使用 优点: 1.减少了时间和空间的开销(new) 2.提高了封装性,使得外部不易改动实例 单线程中: Singleton* getinstance() { if(instance == NULL) { instanc 阅读全文
posted @ 2021-07-16 01:08 Azuki_op 阅读(28) 评论(0) 推荐(0)
摘要: int main { QTextCodec *codec = QTextCodex::codexForName("UTF-8"); QTextCodec::setCodeForLocale(codec); QTextCodec::setCodeForCStrings(codec); QTextCod 阅读全文
posted @ 2021-07-16 01:02 Azuki_op 阅读(135) 评论(0) 推荐(0)
摘要: #include <Tlhelp32.h> #include <windows.h> #include <tlhelp32.h> #include "psapi.h" #include <Tlhelp32.h> void terminateMYSQL() { HANDLE hSnapShot=Cre 阅读全文
posted @ 2021-07-16 00:56 Azuki_op 阅读(776) 评论(0) 推荐(0)
摘要: #!/bin/sh command="/usr/local/Presto/presto-server-0.100/bin/launcher run" #路径 appname=presto-server #进程名 logfile=/usr/local/log/presto_monitor.log #l 阅读全文
posted @ 2021-07-16 00:52 Azuki_op 阅读(281) 评论(0) 推荐(0)
摘要: #include <math.h> #include <QSqlDatabase> #include <QSqlQuery> #include <QSqlError> #include <QNetworkAddressEntry> #include <QNetworkInterface> priva 阅读全文
posted @ 2021-07-16 00:46 Azuki_op 阅读(901) 评论(0) 推荐(0)
摘要: void Parse::sysshutdown() { // Mymethod::record(QString("Switch machine message received")); QProcess *parent; QString program = "sudo"; QStringList a 阅读全文
posted @ 2021-07-16 00:33 Azuki_op 阅读(216) 评论(0) 推荐(0)
上一页 1 ··· 8 9 10 11 12 13 下一页