MCPcopy Create free account
hub / github.com/SFML/SFML / tell

Method tell

src/SFML/System/FileInputStream.cpp:127–141  ·  view source on GitHub ↗

///////////////////////////////////////////////////////

Source from the content-addressed store, hash-verified

125
126////////////////////////////////////////////////////////////
127std::optional<std::size_t> FileInputStream::tell()
128{
129#ifdef SFML_SYSTEM_ANDROID
130 if (priv::getActivityStatesPtr() != nullptr)
131 {
132 if (!m_androidFile)
133 return std::nullopt;
134 return m_androidFile->tell();
135 }
136#endif
137 if (!m_file)
138 return std::nullopt;
139 const auto position = std::ftell(m_file.get());
140 return position < 0 ? std::nullopt : std::optional<std::size_t>(position);
141}
142
143
144////////////////////////////////////////////////////////////

Callers 12

openMethod · 0.45
skipFunction · 0.45
eofFunction · 0.45
streamTellFunction · 0.45
streamEofFunction · 0.45
seekCallbackFunction · 0.45
tellCallbackFunction · 0.45
seekFunction · 0.45
tellFunction · 0.45
onSeekFunction · 0.45

Calls 1

getMethod · 0.80

Tested by

no test coverage detected