⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 atsvalue.h

📁 AtScript 1.1 一个很好用的脚本引擎,可以很方便的在你的软件中实现脚本功能,支持用户扩展对象
💻 H
字号:
// AtsValue.h: interface for the CAtsValue class.
//
//////////////////////////////////////////////////////////////////////

#if !defined(AFX_ATSVALUE_H__BA27B697_5F9B_41D1_9B4F_4742741D696C__INCLUDED_)
#define AFX_ATSVALUE_H__BA27B697_5F9B_41D1_9B4F_4742741D696C__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000

#include "afx.h"
#include "AtsObj.h"
#include "AtsObjPtr.h"

class CAtsObject;
class CAtsEngine;

/////////////////////////////////////////////////
// 值对象
/////////////////////////////////////////////////
class CAtsValue : public CAtsObj  
{
public:
	CAtsValue();
	virtual ~CAtsValue();

	int						m_nType;
	double					m_dData;
	CString					m_strData;		// 字符串: 不含引号
	bool					m_bError;
	CAtsObjPtr<CAtsObject>	m_pObject;

	static double		Dec(const CString& val);
	static CString		Repeat(  char cItem , int nCount );
	CString				Hex(int val, int len = -1);
	CString				Bin(int val, int len = -1);
	static BOOL			IsNumType(int nType);
	BOOL				IsNum();
	CString				FormatData( int nType );
	BOOL				CmpData( CAtsValue *pValue );
	void				SetType( int nType );
	void				AddParamToFist( CAtsValue *pValue );
	void				AddData( CAtsValue *pValue);
	void				SubData( CAtsValue &Value );
	CString				GetStrData();
	void				SetData( LPCTSTR strData  );
	void				SetData( double dData );
	void				SetDataEx( CString strData , int nType );
	void				SetData( CAtsObject *pObject );
	void				SetData( CAtsValue *pData );

	operator = ( const CAtsValue &Item );

	static void OptimizeByNum(CString &strData);
	static CString PrecisionByNum(CString strData, int nPrecision, BOOL bDelInvalidZero);
	static CString PrecisionByNum( double dData, int nPrecision, BOOL bDelInvalidZero);
};

#endif // !defined(AFX_ATSVALUE_H__BA27B697_5F9B_41D1_9B4F_4742741D696C__INCLUDED_)

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -