// BLFolderScheduling.h: interface for the CBLFolderScheduling class. // ////////////////////////////////////////////////////////////////////// #if !defined(AFX_BLFOLDERSCHEDULING_H__2C8D9E82_222F_41FD_A78D_C17563334CA1__INCLUDED_) #define AFX_BLFOLDERSCHEDULING_H__2C8D9E82_222F_41FD_A78D_C17563334CA1__INCLUDED_ #if _MSC_VER > 1000 #pragma once #endif // _MSC_VER > 1000 #define TARGETTYPE_FOLDER 1 #define TARGETTYPE_FILE 2 struct SSubPathInfo { CString s_strItemPath; CString s_strItemName; long s_nCreateDate; int s_nItemType; SSubPathInfo() { Reset(); } void Reset() { s_strItemPath = _T(""); s_strItemName = _T(""); s_nCreateDate = 0; s_nItemType = 0; } // º¹»ç »ý¼ºÀÚ. SSubPathInfo(const SSubPathInfo& rhs) { if(this != &rhs) { s_strItemPath = rhs.s_strItemPath; s_strItemName = rhs.s_strItemName; s_nCreateDate = rhs.s_nCreateDate; s_nItemType = rhs.s_nItemType; } } // ´ëÀÔ¿¬»êÀÚ ¿À¹ö·Îµù. SSubPathInfo& operator=(const SSubPathInfo& rhs) { if(this != &rhs) { s_strItemPath = rhs.s_strItemPath; s_strItemName = rhs.s_strItemName; s_nCreateDate = rhs.s_nCreateDate; s_nItemType = rhs.s_nItemType; } return *this; } }; class AFX_EXT_CLASS CBLFolderScheduling { public: CBLFolderScheduling(); CBLFolderScheduling(CString strPath); CBLFolderScheduling(CString strPath, int nTargetType); virtual ~CBLFolderScheduling(); BOOL SetRemainDelete(CString strPath, int nTargetType, int nRemainItemCount); BOOL CommitSchedule(); void ResetSchedule(); protected: BOOL SearchSubItem(const CString &strMainPath, BOOL bIsAscending); BOOL SortSubItem(BOOL bIsAscending); // ¿À¸§Â÷¼ø TRUE, ³»¸²Â÷¼ø FALSE BOOL DeleteFolder(const CString &strFolder); // °ü¸®¸¦ ÇÒ ÃÖ»óÀ§ °æ·Î. CString m_strMainPath; BOOL m_bTargetFolder; BOOL m_bTargetFile; BOOL m_bIsAscending; // ÀϺθ¸ ³²±â°í »èÁ¦. int m_nRemainItemCount; // °ü¸® ´ë»ó Á¤º¸ SSubPathInfo* m_pPathInfo; int m_nSubItemCount; }; #endif // !defined(AFX_BLFOLDERSCHEDULING_H__2C8D9E82_222F_41FD_A78D_C17563334CA1__INCLUDED_)