// ManagerInstantMemory.h: interface for the CManagerInstantMemory class. // ////////////////////////////////////////////////////////////////////// #if !defined(AFX_MANAGERINSTANTMEMORY_H__62EF5B74_2C69_4D54_AAC6_0597CE40BA6A__INCLUDED_) #define AFX_MANAGERINSTANTMEMORY_H__62EF5B74_2C69_4D54_AAC6_0597CE40BA6A__INCLUDED_ #if _MSC_VER > 1000 #pragma once #endif // _MSC_VER > 1000 #include "IncludeAll.h" #include "ManagerBase.h" typedef struct { int m_iIndex; // À§Ä¡ int m_iSize; // Å©±â } St_InstantMemoryRecycle; class CManagerInstantMemory : public CManagerBase { public: CManagerInstantMemory(); virtual ~CManagerInstantMemory(); virtual void Clear( void); virtual BOOL Create( CDrawBase *pParentDraw, void *pParam); virtual void Destroy( void); /// @name ¸Þ¸ð¸® ÇÒ´ç public: virtual void* Alloc( int iSize); ///< ÇÒ´ç virtual void Free( void *pPtr); ///< Á¦°Å (½ÇÁ¦ÀûÀ¸·Î ÇÏ´Â ÀÏ ¾øÀ½) void Flush( void); ///< ¸ðµÎ ºñ¿ò (ÇÑ ÇÁ·¹ÀÓÀ» ¸ðµÎ ±×¸° ÈÄ¿¡ ºñ¿î´Ù) virtual int GetRollBackPoint( void); ///< µÇµ¹¸± À§Ä¡ ¾ò±â virtual BOOL RollBack( int iRollBackPoint); ///< µÇµ¹¸®±â /// @name ¸Þ¸ð¸® °ü¸® protected: BYTE *m_pMemoryPool; ///< ¸Þ¸ð¸® Ç® int m_iMemoryPoolSize; ///< Àüü ¿ë·® int m_iUsedMemoryPool; ///< »ç¿ëµÈ ¿ë·® int m_iFreedMemoryPool; ///< ÇÒ´ç ÇØÁ¦µÈ ¿ë·® int m_iMaxUsedMemoryPool; ///< ÇöÀç±îÁö m_iUsedMemoryPool ÀÇ ÃÖ´ë°ª (Åë°èÀÚ·á) void AllocateMemoryPool( int iSize); /* /// @name ÇØÁ¦µÈ ¸Þ¸ð¸® Àç»ç¿ë protected: CWzArray m_arRecycle; void AddRecycleMemory( int iStartIndex, int iSize); void RemoveRecycleMemory( int iIndex); BYTE* AllocAsRecycledMemory( int iSize);*/ }; #endif // !defined(AFX_MANAGERINSTANTMEMORY_H__62EF5B74_2C69_4D54_AAC6_0597CE40BA6A__INCLUDED_)