1
0
Fork 0
mirror of https://github.com/Ryujinx/Ryujinx.git synced 2024-10-01 12:30:00 +02:00
Ryujinx/Ryujinx.Common/Logging/LogEventArgs.cs
jduncanator 8406ec6272 Refactor Ryujinx.Common and HLE Stub Logging (#537)
* Refactor Ryujinx.Common and HLE Stub Logging

* Resolve review comments

* Rename missed loop variable

* Optimize PrintStub logging function

* Pass the call-sites Thread ID through to the logger

* Remove superfluous lock from ConsoleLog

* Process logged data objects in the logger target

Pass the data object all the way to the output logger targets, to allow them to "serialize" this in whatever appropriate format they're logging in.

* Use existing StringBuilder to build the properties string

* Add a ServiceNotImplemented Exception

Useful for printing debug information about unimplemented service calls

* Resolve Style Nits

* Resolve Merge Issues

* Fix typo and align declarations
2019-01-11 01:11:46 +01:00

31 lines
No EOL
930 B
C#

using System;
namespace Ryujinx.Common.Logging
{
public class LogEventArgs : EventArgs
{
public LogLevel Level { get; private set; }
public TimeSpan Time { get; private set; }
public int ThreadId { get; private set; }
public string Message { get; private set; }
public object Data { get; private set; }
public LogEventArgs(LogLevel level, TimeSpan time, int threadId, string message)
{
this.Level = level;
this.Time = time;
this.ThreadId = threadId;
this.Message = message;
}
public LogEventArgs(LogLevel level, TimeSpan time, int threadId, string message, object data)
{
this.Level = level;
this.Time = time;
this.ThreadId = threadId;
this.Message = message;
this.Data = data;
}
}
}