Updated archive.cpp functions for proper error handling

This commit is contained in:
archshift 2014-11-24 15:45:20 -08:00
parent e5ff01c2cd
commit 139a4d91d9
5 changed files with 41 additions and 94 deletions

View file

@ -50,7 +50,7 @@ ResultVal<Handle> OpenFileFromArchive(Handle archive_handle, const FileSys::Path
* @param path Path to the File inside of the Archive
* @return Whether deletion succeeded
*/
Result DeleteFileFromArchive(Handle archive_handle, const FileSys::Path& path);
ResultCode DeleteFileFromArchive(Handle archive_handle, const FileSys::Path& path);
/**
* Rename a File between two Archives
@ -60,8 +60,8 @@ Result DeleteFileFromArchive(Handle archive_handle, const FileSys::Path& path);
* @param dest_path Path to the File inside of the destination Archive
* @return Whether rename succeeded
*/
Result RenameFileBetweenArchives(Handle src_archive_handle, const FileSys::Path& src_path,
Handle dest_archive_handle, const FileSys::Path& dest_path);
ResultCode RenameFileBetweenArchives(Handle src_archive_handle, const FileSys::Path& src_path,
Handle dest_archive_handle, const FileSys::Path& dest_path);
/**
* Delete a Directory from an Archive
@ -69,7 +69,7 @@ Result RenameFileBetweenArchives(Handle src_archive_handle, const FileSys::Path&
* @param path Path to the Directory inside of the Archive
* @return Whether deletion succeeded
*/
Result DeleteDirectoryFromArchive(Handle archive_handle, const FileSys::Path& path);
ResultCode DeleteDirectoryFromArchive(Handle archive_handle, const FileSys::Path& path);
/**
* Create a Directory from an Archive
@ -77,7 +77,7 @@ Result DeleteDirectoryFromArchive(Handle archive_handle, const FileSys::Path& pa
* @param path Path to the Directory inside of the Archive
* @return Whether creation of directory succeeded
*/
Result CreateDirectoryFromArchive(Handle archive_handle, const FileSys::Path& path);
ResultCode CreateDirectoryFromArchive(Handle archive_handle, const FileSys::Path& path);
/**
* Rename a Directory between two Archives
@ -87,8 +87,8 @@ Result CreateDirectoryFromArchive(Handle archive_handle, const FileSys::Path& pa
* @param dest_path Path to the Directory inside of the destination Archive
* @return Whether rename succeeded
*/
Result RenameDirectoryBetweenArchives(Handle src_archive_handle, const FileSys::Path& src_path,
Handle dest_archive_handle, const FileSys::Path& dest_path);
ResultCode RenameDirectoryBetweenArchives(Handle src_archive_handle, const FileSys::Path& src_path,
Handle dest_archive_handle, const FileSys::Path& dest_path);
/**
* Open a Directory from an Archive