Created
September 16, 2010 11:26
-
-
Save olim7t/582286 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Basic j.u.l config for simple projects */ | |
import java.util.logging.Level; | |
import java.util.logging.Logger; | |
public class Jul{ | |
static { | |
Logger.getLogger("").setLevel(Level.SEVERE); | |
final Logger myLogger = Logger.getLogger("com.mycompany"); | |
myLogger.setLevel(Level.FINEST); | |
} | |
public static void main(final String[] args) { | |
Logger.getLogger("com.mycompany").info("Should log"); | |
Logger.getLogger("com.mycompany.Test").info("Should log"); | |
Logger.getLogger("com.othercompany.Test").info("Should not log"); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment