You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
|
|
#include "iXmlBaseItem.h"
|
|
|
|
|
|
|
|
|
|
/// @brief 字段类型
|
|
|
|
|
enum FieldInfoType
|
|
|
|
|
{
|
|
|
|
|
FIT_String = 0, //字符串(文本)
|
|
|
|
|
FIT_Int, //整形(含枚举)
|
|
|
|
|
FIT_Double, //Double数值
|
|
|
|
|
FIT_Image, //图像
|
|
|
|
|
FIT_Binary, //二进制
|
|
|
|
|
FIT_DateTime, //日期类型,2017022增加日期类型 数值为5
|
|
|
|
|
|
|
|
|
|
FIT_UNKNOWN
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
/// @brief 字段信息
|
|
|
|
|
class I_XMLMANAGER_EXPORT iXmlField : public iXmlBaseItem
|
|
|
|
|
{
|
|
|
|
|
public:
|
|
|
|
|
|
|
|
|
|
iXmlField(QObject* parent = 0);
|
|
|
|
|
~iXmlField();
|
|
|
|
|
|
|
|
|
|
// 把List分配到成员变量
|
|
|
|
|
// 输入开始的m_listValues中index,并且返回下一个index
|
|
|
|
|
virtual int allocateInfo(int nIndex);
|
|
|
|
|
|
|
|
|
|
protected:
|
|
|
|
|
virtual void initXmlTags();
|
|
|
|
|
|
|
|
|
|
public:
|
|
|
|
|
|
|
|
|
|
QString m_sAlias; //中文名称
|
|
|
|
|
bool m_bKey; //是否关键字
|
|
|
|
|
QString m_sUnit; //单位
|
|
|
|
|
FieldInfoType m_oDataType; //类型
|
|
|
|
|
double m_fMax; //对于数值型有效,最大值,默认值为100
|
|
|
|
|
double m_fMin; //对于数值型有效,最小值,默认为0
|
|
|
|
|
int m_nDigit; //小数位数,默认为3
|
|
|
|
|
|
|
|
|
|
bool m_bVisible; //20180314是否显示在界面上
|
|
|
|
|
|
|
|
|
|
QString m_sOthers;//其它辅助信息,扩展用//20190306
|
|
|
|
|
};
|
|
|
|
|
typedef QVector<iXmlField*> vecXmlFieldsPtr;
|