2
using ServiceStack.Logging.Support.Logging;
4
namespace ServiceStack.Logging
7
/// Logging API for this library. You can inject your own implementation otherwise
8
/// will use the DebugLogFactory to write to System.Diagnostics.Debug
10
public class LogManager
12
private static ILogFactory logFactory;
15
/// Gets or sets the log factory.
16
/// Use this to override the factory that is used to create loggers
18
/// <value>The log factory.</value>
19
public static ILogFactory LogFactory
23
if (logFactory == null)
25
return new DebugLogFactory();
29
set { logFactory = value; }
35
/// <param name="type">The type.</param>
36
/// <returns></returns>
37
public static ILog GetLogger(Type type)
39
return LogFactory.GetLogger(type);
45
/// <param name="typeName">Name of the type.</param>
46
/// <returns></returns>
47
public static ILog GetLogger(string typeName)
49
return LogFactory.GetLogger(typeName);