/*---------------------------------------------------------------------------* Project: Horizon File: fs_IpcFile.h Copyright (C)2009 Nintendo Co., Ltd. All rights reserved. These coded instructions, statements, and computer programs contain proprietary information of Nintendo of America Inc. and/or Nintendo Company Ltd., and are protected by Federal copyright law. They may not be disclosed to third parties or copied or duplicated in any form, in whole or in part, without the prior written consent of Nintendo. $Rev: 21127 $ *---------------------------------------------------------------------------*/ // // このファイルを編集しないでください。 // このファイルは自動生成されます。 // #ifndef NN_FS_FS_IPCFILE_H_ #define NN_FS_FS_IPCFILE_H_ #include #include #include #include namespace nn { namespace fs { namespace ipc { class File { public: enum Tag { TAG_IPC_ERROR, TAG_OPEN_SUB_FILE, TAG_READ, TAG_WRITE, TAG_GET_SIZE, TAG_SET_SIZE, TAG_GET_ATTRIBUTES, TAG_SET_ATTRIBUTES, TAG_CLOSE, TAG_IPC_END }; private: Handle m_Session; public: File(Handle session) : m_Session(session) {} public: nn::Result OpenSubFile( nn::Handle* pOut, s64 offset, s64 length ); nn::Result Read( s32* pRead, s64 offset, void* pBuffer, size_t size ); nn::Result Write( s32* pWritten, s64 offset, const void* pBuffer, size_t size, bool flush ); nn::Result GetSize( s64* pOut ); nn::Result SetSize( s64 size ); nn::Result GetAttributes( nn::fs::Attributes* pOut ); nn::Result SetAttributes( nn::fs::Attributes attributes ); nn::Result Close(); }; } // end of namespace ipc } // end of namespace fs } // end of namespace nn #endif // ifndef NN_FS_FS_IPCFILE_H_