2020-11-11 18:31:26 -05:00
|
|
|
|
using System;
|
|
|
|
|
using Microsoft.Extensions.Logging;
|
|
|
|
|
using ILogger = SharedLibraryCore.Interfaces.ILogger;
|
2017-05-27 19:29:20 -04:00
|
|
|
|
|
2018-04-08 14:48:40 -04:00
|
|
|
|
namespace IW4MAdmin.Application
|
2017-05-27 19:29:20 -04:00
|
|
|
|
{
|
2020-11-11 18:31:26 -05:00
|
|
|
|
[Obsolete]
|
2020-02-11 17:44:06 -05:00
|
|
|
|
public class Logger : ILogger
|
2017-05-27 19:29:20 -04:00
|
|
|
|
{
|
2020-11-11 18:31:26 -05:00
|
|
|
|
private readonly Microsoft.Extensions.Logging.ILogger _logger;
|
2018-10-07 22:34:30 -04:00
|
|
|
|
|
2020-11-11 18:31:26 -05:00
|
|
|
|
public Logger(ILogger<Logger> logger)
|
2019-11-15 15:50:20 -05:00
|
|
|
|
{
|
2020-11-11 18:31:26 -05:00
|
|
|
|
_logger = logger;
|
2017-05-27 19:29:20 -04:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public void WriteVerbose(string msg)
|
|
|
|
|
{
|
2020-11-11 18:31:26 -05:00
|
|
|
|
_logger.LogInformation(msg);
|
2017-05-27 19:29:20 -04:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public void WriteDebug(string msg)
|
|
|
|
|
{
|
2020-11-11 18:31:26 -05:00
|
|
|
|
_logger.LogDebug(msg);
|
2017-05-27 19:29:20 -04:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public void WriteError(string msg)
|
|
|
|
|
{
|
2020-11-11 18:31:26 -05:00
|
|
|
|
_logger.LogError(msg);
|
2017-05-27 19:29:20 -04:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public void WriteInfo(string msg)
|
|
|
|
|
{
|
2020-11-11 18:31:26 -05:00
|
|
|
|
WriteVerbose(msg);
|
2017-05-27 19:29:20 -04:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public void WriteWarning(string msg)
|
|
|
|
|
{
|
2020-11-11 18:31:26 -05:00
|
|
|
|
_logger.LogWarning(msg);
|
2017-05-27 19:29:20 -04:00
|
|
|
|
}
|
2017-11-13 16:58:23 -05:00
|
|
|
|
|
|
|
|
|
public void WriteAssert(bool condition, string msg)
|
|
|
|
|
{
|
2020-11-11 18:31:26 -05:00
|
|
|
|
throw new NotImplementedException();
|
2017-11-13 16:58:23 -05:00
|
|
|
|
}
|
2017-05-27 19:29:20 -04:00
|
|
|
|
}
|
|
|
|
|
}
|