1 /*---------------------------------------------------------------------------* 2 Project: Horizon 3 File: fs_Directory.h 4 5 Copyright (C)2009-2012 Nintendo Co., Ltd. All rights reserved. 6 7 These coded instructions, statements, and computer programs contain 8 proprietary information of Nintendo of America Inc. and/or Nintendo 9 Company Ltd., and are protected by Federal copyright law. They may 10 not be disclosed to third parties or copied or duplicated in any form, 11 in whole or in part, without the prior written consent of Nintendo. 12 13 $Rev: 46347 $ 14 *---------------------------------------------------------------------------*/ 15 16 #ifndef NN_FS_FS_DIRECTORY_H_ 17 #define NN_FS_FS_DIRECTORY_H_ 18 19 #include <nn/Handle.h> 20 #include <nn/Result.h> 21 #include <nn/types.h> 22 #include <nn/util/util_Result.h> 23 #include <nn/fs/fs_Parameters.h> 24 #include <nn/fs/fs_DirectoryBase.h> 25 26 #include <nn/fs/fs_DirectoryBase.h> 27 28 namespace nn { 29 namespace fs { 30 31 /* Please see man pages for details 32 33 34 35 36 37 38 39 40 41 42 43 */ 44 class Directory : private nn::util::NonCopyable<Directory>, private detail::DirectoryBase 45 { 46 public: 47 48 /* Please see man pages for details 49 50 51 52 53 54 55 56 57 */ Directory()58 Directory() {} 59 60 /* Please see man pages for details 61 62 63 64 65 66 67 68 */ Directory(const wchar_t * pathName)69 explicit Directory( const wchar_t* pathName ) : DirectoryBase(pathName) {} 70 71 /* Please see man pages for details 72 73 74 75 76 77 78 79 80 81 82 */ Directory(const char * pathName)83 explicit Directory( const char* pathName ) : DirectoryBase(pathName) {} 84 85 /* Please see man pages for details 86 87 88 89 90 91 92 93 94 */ Initialize(const wchar_t * pathName)95 void Initialize( const wchar_t* pathName ) { DirectoryBase::Initialize(pathName); } 96 97 /* Please see man pages for details 98 99 100 101 102 103 104 105 106 107 108 109 */ Initialize(const char * pathName)110 void Initialize( const char* pathName ) { DirectoryBase::Initialize(pathName); } 111 112 /* Please see man pages for details 113 114 115 116 117 118 119 120 121 122 123 */ TryInitialize(const wchar_t * pathName)124 Result TryInitialize( const wchar_t* pathName ) { return DirectoryBase::TryInitialize(pathName); } 125 126 /* Please see man pages for details 127 128 129 130 131 132 133 134 135 136 137 138 139 140 */ TryInitialize(const char * pathName)141 Result TryInitialize( const char* pathName ) { return DirectoryBase::TryInitialize(pathName); } 142 143 /* Please see man pages for details 144 145 146 147 */ Finalize()148 void Finalize() { DirectoryBase::Finalize(); } 149 150 /* Please see man pages for details 151 152 153 154 */ ~Directory()155 virtual ~Directory() {} 156 157 /* Please see man pages for details 158 159 160 161 162 163 164 165 166 167 */ Read(DirectoryEntry pEntries[],s32 numEntries)168 s32 Read( DirectoryEntry pEntries[], s32 numEntries ) { return DirectoryBase::Read(pEntries, numEntries); } 169 170 /* Please see man pages for details 171 172 173 174 175 176 177 178 179 180 181 */ TryRead(s32 * pNumEntriesOut,DirectoryEntry pEntries[],s32 numEntries)182 Result TryRead( s32* pNumEntriesOut, DirectoryEntry pEntries[], s32 numEntries ) { return DirectoryBase::TryRead(pNumEntriesOut, pEntries, numEntries); } 183 184 /* Please see man pages for details 185 186 187 188 189 190 191 192 */ SetPriority(s32 priority)193 void SetPriority(s32 priority) { detail::DirectoryBase::SetPriority(priority); } 194 195 /* Please see man pages for details 196 197 198 199 200 201 202 203 */ TrySetPriority(s32 priority)204 Result TrySetPriority(s32 priority) { return detail::DirectoryBase::TrySetPriority(priority); } 205 206 207 /* Please see man pages for details 208 209 210 211 212 213 214 215 216 */ GetPriority(s32 * pOut)217 void GetPriority(s32* pOut) const { detail::DirectoryBase::GetPriority(pOut); } 218 219 /* Please see man pages for details 220 221 222 223 224 225 226 227 228 229 230 */ TryGetPriority(s32 * pOut)231 Result TryGetPriority(s32* pOut) const { return detail::DirectoryBase::TryGetPriority(pOut); } 232 }; 233 234 } // end of namespace fs 235 } // end of namespace nn 236 237 #endif // ifndef NN_FS_FS_DIRECTORY_H_ 238