MCPcopy Create free account
hub / github.com/MyGUI/mygui / getData

Method getData

Platforms/OpenGLES/OpenGLESPlatform/src/MyGUI_OpenGLESDataManager.cpp:30–45  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

28 }
29
30 IDataStream* OpenGLESDataManager::getData(const std::string& _name) const
31 {
32 std::string filepath = getDataPath(_name);
33 if (filepath.empty())
34 return nullptr;
35
36 auto stream = std::make_unique<std::ifstream>();
37 stream->open(filepath.c_str(), std::ios_base::binary);
38
39 if (!stream->is_open())
40 return nullptr;
41
42 DataFileStream* data = new DataFileStream(std::move(stream));
43
44 return data;
45 }
46
47 void OpenGLESDataManager::freeData(IDataStream* _data)
48 {

Callers

nothing calls this directly

Calls 3

emptyMethod · 0.45
openMethod · 0.45
c_strMethod · 0.45

Tested by

no test coverage detected