com.jpattern.orm.logger.OrmLogger Maven / Gradle / Ivy
package com.jpattern.orm.logger;
import com.jpattern.logger.ILogger;
import com.jpattern.logger.ILoggerFactory;
import com.jpattern.logger.Slf4JLoggerFactory;
/**
*
* @author Francesco Cina
*
* 04/giu/2011
*/
public abstract class OrmLogger {
/**
*
*/
private static ILoggerFactory ormLoggerFactory;
public static void setOrmLoggerFactory(ILoggerFactory ormLoggerFactory) {
OrmLogger.ormLoggerFactory = ormLoggerFactory;
}
public static ILogger getOrmLogger(Class> clazz) {
if ( ormLoggerFactory == null ) {
ormLoggerFactory = new Slf4JLoggerFactory();
}
return ormLoggerFactory.logger(clazz);
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy