MCPcopy Create free account
hub / github.com/FlaxEngine/FlaxEngine / Dispose

Method Dispose

Source/Engine/Core/Log.cpp:186–209  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

184}
185
186void Log::Logger::Dispose()
187{
188 LogLocker.Lock();
189
190 // Write ending info
191 WriteFloor();
192#if LOG_ENABLE_FILE
193 Write(String::Format(TEXT(" Total errors: {0}\n Closing file"), LogTotalErrorsCnt, DateTime::Now().ToString()));
194#else
195 Write(String::Format(TEXT(" Total errors: {0}"), LogTotalErrorsCnt));
196#endif
197 WriteFloor();
198
199 // Close
200 if (LogAfterInit)
201 {
202 LogAfterInit = false;
203 LogFile->Close();
204 Delete(LogFile);
205 LogFile = nullptr;
206 }
207
208 LogLocker.Unlock();
209}
210
211bool Log::Logger::IsLogEnabled()
212{

Callers

nothing calls this directly

Calls 7

DeleteFunction · 0.85
LockMethod · 0.80
UnlockMethod · 0.80
WriteFunction · 0.70
FormatFunction · 0.50
ToStringMethod · 0.45
CloseMethod · 0.45

Tested by

no test coverage detected