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

📄 sub_person.h

📁 一个用HLA编写的聊天程序
💻 H
字号:
/**********************************************************************************

						欢迎使用FFB-MOT对象模板V1.1
						设计者:尹娟,龚建兴
						Email:fj_gjx@yahoo.com
						Phone:0731-4574996
						日期 :2003.8.25

**********************************************************************************/
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
#ifndef	FWSUB_PERSON_H_
#define FWSUB_PERSON_H_

#include "DataTypeDef.h"
#include "FWBaseClass.h"

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

//{{FW_OBJECT_INFOMATION_BEGIN
// OMT_NAME: Person
// OMT_PS: S
// OMT_DESCRIPTION: 
//}}FW_OBJECT_INFOMATION_END

class CSub_Person : public CFWBaseClass
{
public:
	CSub_Person();

//Attribute
public:
	//{{FW_PUBLIC_OMT_ATTRIBUTE_VALUE_DECLARE_BEGIN <<----- Don't delete it!>>
	// 聊天者年级
	unsigned long	m_age;
	// 
	std::string	m_real_name;
	// 
	std::string	m_user_name;
	//}}FW_PUBLIC_OMT_ATTRIBUTE_VALUE_DECLARE_END <<----- Don't delete it!>>

private:
	//{{FW_PRIVATE_OMT_ATTRIBUTE_FLAG_DECLARE_BEGIN <<----- Don't delete it!>>
	RTI::Boolean	ms_IsReflectedage;
	RTI::Boolean	ms_IsReflectedreal_name;
	RTI::Boolean	ms_IsReflecteduser_name;
	//}}FW_PRIVATE_OMT_ATTRIBUTE_FLAG_DECLARE_END <<----- Don't delete it!>>

	//{{FW_PRIVATE_STATIC_ATTRIBUTE_DECLARE_BEGIN <<----- Don't delete it!>>
	static RTI::ObjectClassHandle	ms_PersonId;
	static char*					ms_PersonStr;
	static RTI::AttributeHandle		ms_ageId;
	static char*					ms_ageStr;
	static RTI::AttributeHandle		ms_real_nameId;
	static char*					ms_real_nameStr;
	static RTI::AttributeHandle		ms_user_nameId;
	static char*					ms_user_nameStr;
	static CStringArray	m_AttrNamesArray;
	//}}FW_PRIVATE_STATIC_ATTRIBUTE_DECLARE_END <<----- Don't delete it!>>

//Method
public:
	//{{FW_PUBLIC_VIRTUAL_METHOD_DECLARE_BEGIN <<----- Don't delete it!>>
	virtual unsigned long GetAttributeCount();
	virtual void ReflectAttributeValues(const RTI::AttributeHandleValuePairSet &theAttributes,
			const RTI::FedTime &theTime);
	virtual void ReflectAttributeValues(const RTI::AttributeHandleValuePairSet &theAttributes);
	virtual RTI::Boolean GetReflectedStatusOfAttr(CString theAttrName);
	virtual void SetReflectedStatusOfAttrs(CStringArray &theAttrNames, RTI::Boolean theStatus);
	//}}FW_PUBLIC_VIRTUAL_METHOD_DECLARE_END <<----- Don't delete it!>>

	//{{FW_PUBLIC_METHOD_DECLARE_BEGIN <<----- Don't delete it!>>
	static void Init(RTI::ObjectClassHandle theObject = 0);
	static RTI::ObjectClassHandle GetClassId();
	static RTI::AttributeHandle FindAttributeHandle(CString theAttrName);
	static RTI::AttributeHandleSet* GetAttributeHandleSet(CStringArray& theAttrNames);
	static void Subscribing();
	static void Unsubscribed();
	//}}FW_PUBLIC_METHOD_DECLARE_END <<----- Don't delete it!>>
};

#endif //FWSUB_PERSON_H_
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////

⌨️ 快捷键说明

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