imgtools/imglib/filesystem/include/dirregion.h
changeset 590 360bd6b35136
parent 0 044383f39525
equal deleted inserted replaced
588:c7c26511138f 590:360bd6b35136
    30 #include <map>
    30 #include <map>
    31 #include <string>
    31 #include <string>
    32 
    32 
    33 class CFileSystem;
    33 class CFileSystem;
    34 
    34 
    35 typedef std::ofstream OfStream;
    35 typedef ofstream OfStream;
    36 typedef std::ifstream IfStream;
    36 typedef ifstream IfStream;
    37 typedef std::ios Ios;
    37 typedef ios Ios;
    38 typedef std::map<unsigned int,std::string> StringMap;
    38 typedef map<unsigned int,string> StringMap;
    39 
    39 
    40 /**
    40 /**
    41 This class describes the member functions and data members required to create directory/data
    41 This class describes the member functions and data members required to create directory/data
    42 region of FAT image.
    42 region of FAT image.
    43 
    43 
    45 @released
    45 @released
    46 */
    46 */
    47 
    47 
    48 class CDirRegion
    48 class CDirRegion
    49 	{
    49 	{
    50 	private:
    50 	private: 
    51 		void FormatName(String& aString,char aAttrValue);
       
    52 		unsigned int Get32BitClusterNumber(unsigned int aHighWord, unsigned int aLowWord);
    51 		unsigned int Get32BitClusterNumber(unsigned int aHighWord, unsigned int aLowWord);
    53 		void CheckEntry(EntryList aNodeList);
    52 		void CheckEntry(EntryList aNodeList);
    54 		void CreateDirEntry(CDirectory* aEntry,unsigned int aParentDirClusterNumber);
    53 		void CreateDirEntry(CDirectory* aEntry,unsigned int aParentDirClusterNumber);
    55 		void CreateAndWriteCurrentDirEntry(unsigned int aCurClusterNumber,String& aString);
    54 		void CreateAndWriteCurrentDirEntry(unsigned int aCurClusterNumber,string& aString);
    56 		void CreateAndWriteParentDirEntry(unsigned int aParDirClusterNumber,String& aString);
    55 		void CreateAndWriteParentDirEntry(unsigned int aParDirClusterNumber,string& aString); 
    57 		void WriteEntryToString(CDirectory* aEntry,String& aString);
       
    58 		bool IsLongEntry(CDirectory* aEntry) const;
       
    59 		void CreateLongEntries(CDirectory* aEntry,String& aDirString);
       
    60 		void WriteFileDataInToCluster(CDirectory* aEntry); 
    56 		void WriteFileDataInToCluster(CDirectory* aEntry); 
    61 		void PushStringIntoClusterMap(unsigned int aNumber, 
    57 		void PushStringIntoClusterMap(unsigned int aNumber, 
    62 									  String& aDirString,
    58 									  string& aDirString,
    63 									  unsigned long int aClusterSize,
    59 									  unsigned long int aClusterSize,
    64 									  char aAttribute);
    60 									  char aAttribute);
    65 		void PushDirectoryEntryString(unsigned int aNumber,String& aString,int aClustersRequired);
    61 		void PushDirectoryEntryString(unsigned int aNumber,string& aString,int aClustersRequired);
    66 
    62 
    67 	public:
    63 	public:
    68 		CDirRegion(	EntryList iNodeList,
    64 		CDirRegion(	EntryList iNodeList,
    69 					CFileSystem *aFileSystemPtr);
    65 					CFileSystem *aFileSystemPtr);
    70 		~CDirRegion();
    66 		~CDirRegion();