# RowCopy **Repository Path**: jiang_c_h_a_o/row-copy ## Basic Information - **Project Name**: RowCopy - **Description**: ntfs exfat cifs 文件系统 解析 - **Primary Language**: C++ - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2025-04-11 - **Last Updated**: 2025-04-11 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # RawCopy ## DumpFile 函数功能:拷贝文件(可以拷贝被占用的文件) 参 数:srcPath:需要拷贝的文件路径 destPath:拷贝后的存放路径 返 回 值:1成功 0失败 ## listFiles 函数功能:遍历文件夹下的所有文件 参 数:directory:要遍历的路径 返 回 值:文件夹下的文件集合 ## InitCifs 函数功能:初始化CIFS(仅CIFS需要) 参 数: host:服务器IP UserName:服务器用户名 RootPath:服务器根目录共享文件夹名称 Path:服务器文件路径 psd:服务器密码 IsXP:服务器系统是否是xp系统 ## NTFS示例 RawCopy rawCopy; rawCopy.DumpFile("C:\\123\\linux-master.zip", "C:\\456"); auto files = rawCopy.listFiles("C:\\Users"); for (const auto& file : files) { std::cout << file.creationTime << " " << (file.isDirectory ? "文件夹" : "文件") << " " << file.size << "\t " << (file.IsReadOnly? 'R' : ' ') << " " << (file.IsHidden ? 'H' : ' ') << " " << (file.IsSystem ? 'S' : ' ') << " " << file.fileName << std::endl; } ## ExFat示例 RawCopy rawCopy; rawCopy.DumpFile("D:\\456\\linux-master.zip", "C:\\456"); auto files = rawCopy.listFiles("D:\\456"); for (const auto& file : files) { std::cout << file.creationTime << " " << (file.isDirectory ? "文件夹" : "文件") << " " << file.size << "\t " << (file.IsReadOnly? 'R' : ' ') << " " << (file.IsHidden ? 'H' : ' ') << " " << (file.IsSystem ? 'S' : ' ') << " " << file.fileName << std::endl; } ## CIFS示例 rawCopy.InitCifs("192.168.63.132", "Administrator", "CIFS-WIN10", "password",true); rawCopy.DumpFile("\\w1\\ww1\\linux-master.zip", "C:\\456"); auto files = rawCopy.listFiles("\\w1\\ww1"); for (const auto& file : files) { std::cout << file.creationTime << " " << (file.isDirectory ? "文件夹" : "文件") << " " << file.size << "\t " << (file.IsReadOnly ? 'R' : ' ') << " " << (file.IsHidden ? 'H' : ' ') << " " << (file.IsSystem ? 'S' : ' ') << " " << file.fileName << std::endl; }