diff options
author | chai <chaifix@163.com> | 2019-08-07 21:08:47 +0800 |
---|---|---|
committer | chai <chaifix@163.com> | 2019-08-07 21:08:47 +0800 |
commit | 0c391fdbce5a079cf03e483eb6174dd47806163d (patch) | |
tree | b06cd7a9d0ae0d9bb9e82f3dcb786dfce11f8628 /source/modules/asura-utils/IO/FileData.cpp | |
parent | 9686368e58e25cbd6dc37d686bdd2be3f80486d6 (diff) |
*misc
Diffstat (limited to 'source/modules/asura-utils/IO/FileData.cpp')
-rw-r--r-- | source/modules/asura-utils/IO/FileData.cpp | 59 |
1 files changed, 0 insertions, 59 deletions
diff --git a/source/modules/asura-utils/IO/FileData.cpp b/source/modules/asura-utils/IO/FileData.cpp deleted file mode 100644 index ca1cce7..0000000 --- a/source/modules/asura-utils/IO/FileData.cpp +++ /dev/null @@ -1,59 +0,0 @@ -#include "FileData.h" - -namespace AsuraEngine -{ - namespace IO - { - - FileData::FileData(const std::string& filename) - : m_Data(nullptr) - , m_FileName(filename) - { - size_t dot = filename.rfind('.'); - if (dot != std::string::npos) - { - m_Extension = filename.substr(dot + 1); - m_Name = filename.substr(0, dot); - } - else - m_Name = filename; - } - - FileData::~FileData() - { - if (m_Data) - m_Data->Release(); - } - - const std::string& FileData::GetFileName() - { - return m_FileName; - } - - const std::string& FileData::GetExtension() - { - return m_Extension; - } - - const std::string& FileData::GetName() - { - return m_Name; - } - - void FileData::BindData(ASURA_MOVE DataBuffer* buffer) - { - if (!buffer) - return; - if (m_Data) - m_Data->Release(); - m_Data = buffer; - m_Data->Retain(); - } - - DataBuffer* FileData::GetDataBuffer() - { - return m_Data; - } - - } -}
\ No newline at end of file |