jochenvanwylick/JVW.Logging — pull request #1 by timba (2014-10-15 18:45:24+00:00)
Title: ILog object obtaining failed if identified by type.

Constructor of class `JVW.Logging.CommonLoggingNLogAdapter.NLogLogger` with this parameter of type `System.Type` `NLogLogger(Type type)` is trying to create internal `NLog.Logger` object using `NLog.LogManager.GetLogger(string name, Type loggerType)` static method. But `loggerType` should be (from NLog documentation):
> // loggerType:
> // The logger class. The class must inherit from NLog.Logger.

So the type should be an actual type of logger (implementation).
The problem is that the corresponding method `GetLogger(Type type)` of interface `Common.Logging.ILoggerFactoryAdapter` supposed to pass "type" parameter not as "type of Logger implementation" but as an identifier of a class which "owns" the logger to be returned.
Using this implementation "as is" causes an exception if one tries to pass any type to `LogManager.GetLogger()` or `LogManager.GetLogger(typeof(Log_Owner_Class))` if `Log_Owner_Class` is not inherited from `NLog.Logger`.
This pull request fixes this issue.