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

📄 bookengine.h

📁 symbian和旗下的HTTPENGINE的相关代码
💻 H
字号:
/*****************************************************************************
*  Name     : BookEngine.h
*  Part of  : FreeSMS
*  Created  : 10.15.2007 by tommy
*  Implementation notes:
*     Initial content was generated by Series 60 Application Wizard.
*  Version  : 1.0
*****************************************************************************/
#ifndef __BOOKENGINE_H__
#define __BOOKENGINE_H__

#include <e32std.h>
#include <cntdef.h>
#include <cntdb.h>
#include <cntfield.h>
#include <cntfldst.h>
#include <cpbkcontactitem.h>
#include <tpbkcontactitemfield.h>
#include <CPbkContactEngine.h>		// CPbkContactEngine
#include <CPbkContactItem.h>		// CPbkContactItem 
#include <CPbkFieldInfo.h>			// CPbkFieldInfo
#include <CPbkFieldsInfo.h>			// CPbkFieldsInfo
#include <MPbkContactDbObserver.h> 

class CBookInfo;

class CBookEngine: public CBase, public MPbkContactDbObserver
{
public:
	void DeleteUserFromBook(TInt aItemID);
//from
	//0: 读取联系人列表
	//1: 写入和修改联系人
	void UpdatePhoneBook(TInt aFlag, RPointerArray<CBookInfo>& aBookInfo);
	void GetMobileNumberByName(const TDesC& aName, TDes& aMobile);
//from MPbkContactDbObserver
	virtual void  HandleDatabaseEventL (TContactDbObserverEvent aEvent); 
//System	
	static CBookEngine* NewL();
	static CBookEngine* NewLC();
	~CBookEngine();
private:
	void ConstructL();
private:
	CContactDatabase*       m_pContacts;    
	CPbkContactEngine*		m_pPbkContactEngine;
};

class CBookInfo: public CBase
{
public:
	static CBookInfo* NewL();
	static CBookInfo* NewLC();
	~CBookInfo();
protected:	
	CBookInfo();
	void ConstructL();
public:
//Operation
	//nServerUID, ClientID, ItemID
	void	SetItemID(TInt aID) {m_nItem_ID = aID;}
	TInt	GetItemID() {return m_nItem_ID;}
	//Last Name
	void	SetLastName(const TDesC& aBuf);
	HBufC*	GetLastName() {return m_sLastName;}
	//first name
	void	SetFirstName(const TDesC& aBuf);
	HBufC*	GetFirstName() {return m_sFirstName;}
	//m_sTelephone
	void	SetTelephone(const TDesC& aBuf);
	HBufC*	GetTelephone() {return m_sTelephone;}
	//m_sHomeTelephone
	void	SetHomeTelephone(const TDesC& aBuf);
	HBufC*	GetHomeTelephone() {return m_sHomeTelephone;}
	//m_sBusinessTelephone
	void	SetBusinessTelephone(const TDesC& aBuf);
	HBufC*	GetBusinessTelephone() {return m_sBusinessTelephone;}
	//m_sHomeMobile
	void	SetHomeMobileNumber(const TDesC& aBuf);
	HBufC*	GetHomeMobileNumber() {return m_sHomeMobile;}
	//m_sModifyTime
	void	SetModifyTime(const TDesC& aBuf);
	HBufC*	GetModifyTime() {return m_sModifyTime;}
	//m_sModifyTime
	void	SetModifyDate(const TDesC& aBuf);
	HBufC*	GetModifyDate() {return m_sModifyDate;}

	void	SetItemMarkState(TBool aState);
	TBool	GetItemMarkState() {return m_eItem_MarkState;}
	
private:
	TInt	m_nItem_ID;
	TBool	m_eItem_MarkState;

	HBufC*	m_sLastName;
	HBufC*	m_sFirstName;

	HBufC*	m_sTelephone;
	HBufC*	m_sHomeTelephone;
	HBufC*	m_sBusinessTelephone;

	HBufC*	m_sHomeMobile;
	HBufC*	m_sModifyTime;
	HBufC*	m_sModifyDate;
};

#endif //__BOOKENGINE_H__

⌨️ 快捷键说明

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