add logger to any object, at instance level and class level