effectprocess 추가
git-svn-id: svn://192.168.0.12/source@305 8346c931-da38-4b9b-9d4c-e48b93cbd075
This commit is contained in:
77
EffectProcess/sutilclass.cpp
Normal file
77
EffectProcess/sutilclass.cpp
Normal file
@@ -0,0 +1,77 @@
|
||||
#include "sutilclass.h"
|
||||
STableWidgetItem::STableWidgetItem(int type): QTableWidgetItem(type)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
STableWidgetItem::STableWidgetItem(const QIcon &icon, const QString &text, int type):
|
||||
QTableWidgetItem(icon, text, type)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
STableWidgetItem::STableWidgetItem(const QString &text, int type):
|
||||
QTableWidgetItem(text, type)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
STableWidgetItem::STableWidgetItem(const QTableWidgetItem &other):
|
||||
QTableWidgetItem(other)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
bool STableWidgetItem::operator <(const QTableWidgetItem &other) const
|
||||
{
|
||||
bool ok1, ok2;
|
||||
int nThis = text().toInt(&ok1);
|
||||
int nOther = other.text().toInt(&ok2);
|
||||
if (ok1 && ok2)
|
||||
{
|
||||
return nThis < nOther;
|
||||
}
|
||||
else
|
||||
{
|
||||
return text() < other.text();
|
||||
}
|
||||
}
|
||||
SError::SError(): company_num(-1), platformname_num(-1)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
|
||||
QString ERROR_MESSAGE[static_cast<int>(E_ERROR_CODE::MAX)] =
|
||||
{
|
||||
"DB_OPEN_ERROR",
|
||||
"DB_FULL_ERROR",
|
||||
"DB_LONG_QUERY_ERROR",
|
||||
"DB_QUERY_ERROR",
|
||||
"DB_UNKNOWN_ERROR",
|
||||
"INTERNET_ERROR",
|
||||
"OUT_DATED_CRAWLER",
|
||||
"DELETED_URL_ERROR",
|
||||
"BLOCK_ERROR",
|
||||
"TIMEOUT",
|
||||
"NO_PROGRAM",
|
||||
"UNKNOWN_ERROR",
|
||||
};
|
||||
|
||||
QString ERROR_MESSAGE_CODE[static_cast<int>(E_ERROR_CODE::MAX)] =
|
||||
{
|
||||
"e000",
|
||||
"e001",
|
||||
"e002",
|
||||
"e003",
|
||||
"e004",
|
||||
"e005",
|
||||
"e006",
|
||||
"e007",
|
||||
"e008",
|
||||
"e009",
|
||||
"e010",
|
||||
"e011",
|
||||
};
|
||||
|
||||
const QString SEPERATOR = "!@#";
|
||||
Reference in New Issue
Block a user