Skip to content

Commit 45c5ce8

Browse files
prateekatknoldusanalytically
authored andcommitted
Included a way to create Logger with class name in which it is defined
1 parent c25b1a2 commit 45c5ce8

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

README.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,12 @@ Or, you pass in a SLF4J logger instance:
5454
val logger = Logger(LoggerFactory.getLogger("name"))
5555
```
5656

57+
Or, you pass in the name of the class into which it is defined:
58+
59+
```scala
60+
val logger = Logger(getClass.getName)
61+
```
62+
5763
Or, you pass in a class:
5864

5965
```scala

0 commit comments

Comments
 (0)