summaryrefslogtreecommitdiff
path: root/src/core/loader/loader.h
diff options
context:
space:
mode:
authorGravatar bunnei2014-06-27 15:33:23 -0400
committerGravatar bunnei2014-06-27 17:49:01 -0400
commitd8da707bb90c233d5e815a508bea3473e6e50afa (patch)
treedd9056678f602276691bb4613ea38c7c2ac9126f /src/core/loader/loader.h
parentFS: Added stubbed code to intercept and decode file system service functions. (diff)
downloadyuzu-d8da707bb90c233d5e815a508bea3473e6e50afa.tar.gz
yuzu-d8da707bb90c233d5e815a508bea3473e6e50afa.tar.xz
yuzu-d8da707bb90c233d5e815a508bea3473e6e50afa.zip
Loader: Refactored interface such that data is no longer stored by loader.
NCCH: Removed extra qualification ‘Loader::AppLoader_NCCH::’.
Diffstat (limited to 'src/core/loader/loader.h')
-rw-r--r--src/core/loader/loader.h54
1 files changed, 21 insertions, 33 deletions
diff --git a/src/core/loader/loader.h b/src/core/loader/loader.h
index 95f16fcb1..7891c1ed7 100644
--- a/src/core/loader/loader.h
+++ b/src/core/loader/loader.h
@@ -48,60 +48,48 @@ public:
48 48
49 /** 49 /**
50 * Get the code (typically .code section) of the application 50 * Get the code (typically .code section) of the application
51 * @param error ResultStatus result of function 51 * @param buffer Reference to buffer to store data
52 * @return Reference to code buffer 52 * @return ResultStatus result of function
53 */ 53 */
54 virtual const std::vector<u8>& ReadCode(ResultStatus& error) const { 54 virtual ResultStatus ReadCode(std::vector<u8>& buffer) {
55 error = ResultStatus::ErrorNotImplemented; 55 return ResultStatus::ErrorNotImplemented;
56 return code;
57 } 56 }
58 57
59 /** 58 /**
60 * Get the icon (typically icon section) of the application 59 * Get the icon (typically icon section) of the application
61 * @param error ResultStatus result of function 60 * @param buffer Reference to buffer to store data
62 * @return Reference to icon buffer 61 * @return ResultStatus result of function
63 */ 62 */
64 virtual const std::vector<u8>& ReadIcon(ResultStatus& error) const { 63 virtual ResultStatus ReadIcon(std::vector<u8>& buffer) {
65 error = ResultStatus::ErrorNotImplemented; 64 return ResultStatus::ErrorNotImplemented;
66 return icon;
67 } 65 }
68 66
69 /** 67 /**
70 * Get the banner (typically banner section) of the application 68 * Get the banner (typically banner section) of the application
71 * @param error ResultStatus result of function 69 * @param buffer Reference to buffer to store data
72 * @return Reference to banner buffer 70 * @return ResultStatus result of function
73 */ 71 */
74 virtual const std::vector<u8>& ReadBanner(ResultStatus& error) const { 72 virtual ResultStatus ReadBanner(std::vector<u8>& buffer) {
75 error = ResultStatus::ErrorNotImplemented; 73 return ResultStatus::ErrorNotImplemented;
76 return banner;
77 } 74 }
78 75
79 /** 76 /**
80 * Get the logo (typically logo section) of the application 77 * Get the logo (typically logo section) of the application
81 * @param error ResultStatus result of function 78 * @param buffer Reference to buffer to store data
82 * @return Reference to logo buffer 79 * @return ResultStatus result of function
83 */ 80 */
84 virtual const std::vector<u8>& ReadLogo(ResultStatus& error) const { 81 virtual ResultStatus ReadLogo(std::vector<u8>& buffer) {
85 error = ResultStatus::ErrorNotImplemented; 82 return ResultStatus::ErrorNotImplemented;
86 return logo;
87 } 83 }
88 84
89 /** 85 /**
90 * Get the RomFs archive of the application 86 * Get the RomFS of the application
91 * @param error ResultStatus result of function 87 * @param buffer Reference to buffer to store data
92 * @return Reference to RomFs archive buffer 88 * @return ResultStatus result of function
93 */ 89 */
94 virtual const std::vector<u8>& ReadRomFS(ResultStatus& error) const { 90 virtual ResultStatus ReadRomFS(std::vector<u8>& buffer) {
95 error = ResultStatus::ErrorNotImplemented; 91 return ResultStatus::ErrorNotImplemented;
96 return romfs;
97 } 92 }
98
99protected:
100 std::vector<u8> code; ///< ExeFS .code section
101 std::vector<u8> icon; ///< ExeFS .icon section
102 std::vector<u8> banner; ///< ExeFS .banner section
103 std::vector<u8> logo; ///< ExeFS .logo section
104 std::vector<u8> romfs; ///< RomFs archive
105}; 93};
106 94
107/** 95/**