Class EoulsanLogger
- java.lang.Object
-
- fr.ens.biologie.genomique.eoulsan.EoulsanLogger
-
public class EoulsanLogger extends Object
This class allow to change the logger name for all Eoulsan classes. The setLoggerName() method must be called before any other Eoulsan method.- Since:
- 2.0
- Author:
- Laurent Jourdren
-
-
Constructor Summary
Constructors Constructor Description EoulsanLogger()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static fr.ens.biologie.genomique.kenetre.log.GenericLogger
getGenericLogger()
static Logger
getLogger()
Get the logger object.static String
getLoggerName()
Get the logger name.static void
initConsoleHandler()
Initialize the console logger handler for Hadoop mappers and reducers.static void
initConsoleHandler(Level level)
Initialize the console logger handler for Hadoop mappers and reducers.static void
logConfig(String msg)
Log a CONFIG message usinggetLogger().config()
.static void
logFiner(String msg)
Log a FINER message usinggetLogger().finer()
.static void
logFinest(String message)
Log a FINEST message usinggetLogger().finest()
.static void
logInfo(String msg)
Log an INFO message usinggetLogger().info()
.static void
logSevere(String msg)
Log an SEVERE message usinggetLogger().severe()
.static void
logWarning(String msg)
Log an WARNING message usinggetLogger().warning()
.static void
registerThreadGroupLogger(ThreadGroup threadGroup, Logger logger)
Register a logger for a thread group.static void
removeThreadGroupLogger(ThreadGroup threadGroup)
Remove a logger for a thread group.static void
setLoggerName(String newLoggerName)
Set the logger name.
-
-
-
Method Detail
-
getLogger
public static Logger getLogger()
Get the logger object.- Returns:
- a logger object for Eoulsan
-
setLoggerName
public static void setLoggerName(String newLoggerName)
Set the logger name.- Parameters:
newLoggerName
- the new logger name
-
getLoggerName
public static String getLoggerName()
Get the logger name.- Returns:
- the logger name
-
registerThreadGroupLogger
public static void registerThreadGroupLogger(ThreadGroup threadGroup, Logger logger)
Register a logger for a thread group.- Parameters:
threadGroup
- thread grouplogger
- logger to register
-
removeThreadGroupLogger
public static void removeThreadGroupLogger(ThreadGroup threadGroup)
Remove a logger for a thread group.- Parameters:
threadGroup
- thread group
-
initConsoleHandler
public static void initConsoleHandler()
Initialize the console logger handler for Hadoop mappers and reducers. This method set the Eoulsan logger format and define the logger level.
-
initConsoleHandler
public static void initConsoleHandler(Level level)
Initialize the console logger handler for Hadoop mappers and reducers.- Parameters:
level
- log level to use
-
logSevere
public static void logSevere(String msg)
Log an SEVERE message usinggetLogger().severe()
.- Parameters:
msg
- The string message
-
logWarning
public static void logWarning(String msg)
Log an WARNING message usinggetLogger().warning()
.- Parameters:
msg
- The string message
-
logInfo
public static void logInfo(String msg)
Log an INFO message usinggetLogger().info()
.- Parameters:
msg
- The string message
-
logConfig
public static void logConfig(String msg)
Log a CONFIG message usinggetLogger().config()
.- Parameters:
msg
- The string message
-
logFiner
public static void logFiner(String msg)
Log a FINER message usinggetLogger().finer()
.- Parameters:
msg
- The string message
-
logFinest
public static void logFinest(String message)
Log a FINEST message usinggetLogger().finest()
.- Parameters:
message
- The string message
-
getGenericLogger
public static fr.ens.biologie.genomique.kenetre.log.GenericLogger getGenericLogger()
-
-