当前位置: 首页>>代码示例>>Java>>正文


Java LoggerFactory类代码示例

本文整理汇总了Java中com.j256.ormlite.logger.LoggerFactory的典型用法代码示例。如果您正苦于以下问题:Java LoggerFactory类的具体用法?Java LoggerFactory怎么用?Java LoggerFactory使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


LoggerFactory类属于com.j256.ormlite.logger包,在下文中一共展示了LoggerFactory类的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: AndroidLog

import com.j256.ormlite.logger.LoggerFactory; //导入依赖的package包/类
public AndroidLog(String paramString)
{
  this.className = LoggerFactory.getSimpleClassName(paramString);
  int i = this.className.length();
  if (i > 23)
    this.className = this.className.substring(i - 23, i);
  int j = 0;
  Log.Level[] arrayOfLevel = Log.Level.values();
  int k = arrayOfLevel.length;
  for (int m = 0; m < k; m++)
  {
    int n = levelToAndroidLevel(arrayOfLevel[m]);
    if (n > j)
      j = n;
  }
  this.levelCache = new boolean[j + 1];
  refreshLevelCache();
}
 
开发者ID:mmmsplay10,项目名称:QuizUpWinner,代码行数:19,代码来源:AndroidLog.java

示例2: AndroidLog

import com.j256.ormlite.logger.LoggerFactory; //导入依赖的package包/类
public AndroidLog(String className) {
	// get the last part of the class name
	this.className = LoggerFactory.getSimpleClassName(className);
	// make sure that our tag length is not too long
	int length = this.className.length();
	if (length > MAX_TAG_LENGTH) {
		this.className = this.className.substring(length - MAX_TAG_LENGTH, length);
	}
	// find the maximum level value
	int maxLevel = 0;
	for (com.j256.ormlite.logger.Log.Level level : com.j256.ormlite.logger.Log.Level.values()) {
		int androidLevel = levelToAndroidLevel(level);
		if (androidLevel > maxLevel) {
			maxLevel = androidLevel;
		}
	}
	levelCache = new boolean[maxLevel + 1];
	refreshLevelCache();
}
 
开发者ID:d-tarasov,项目名称:ormlite-android-sqlcipher,代码行数:20,代码来源:AndroidLog.java

示例3: initializeDb

import com.j256.ormlite.logger.LoggerFactory; //导入依赖的package包/类
public static void initializeDb() throws SQLException {
    //TODO combine logging
    System.setProperty(LoggerFactory.LOG_TYPE_SYSTEM_PROPERTY,
            LoggerFactory.LogType.LOCAL.toString());
    System.setProperty(LocalLog.LOCAL_LOG_LEVEL_PROPERTY,
            Log.Level.INFO.toString());

    INSTANCE = new VaultDao();
    INSTANCE.initDb();
}
 
开发者ID:tiweGH,项目名称:OpenDiabetes,代码行数:11,代码来源:VaultDao.java

示例4: initializeDb

import com.j256.ormlite.logger.LoggerFactory; //导入依赖的package包/类
/**
 * Initializes the connection to the database and sets up the Vault Database Access Object {@link #INSTANCE}.
 *
 * @throws SQLException Thrown if the database can not be successfully initialized.
 */
public static void initializeDb() throws SQLException {
    //TODO combine logging
    System.setProperty(LoggerFactory.LOG_TYPE_SYSTEM_PROPERTY,
            LoggerFactory.LogType.LOCAL.toString());
    System.setProperty(LocalLog.LOCAL_LOG_LEVEL_PROPERTY,
            Log.Level.INFO.toString());

    INSTANCE = new VaultDao();
    INSTANCE.initDb();
}
 
开发者ID:lucasbuschlinger,项目名称:BachelorPraktikum,代码行数:16,代码来源:VaultDao.java

示例5: getLogger

import com.j256.ormlite.logger.LoggerFactory; //导入依赖的package包/类
/**
 * Get the logger for the class. We do this so we don't have to create it all of the time.
 */
private static Logger getLogger() {
	if (logger == null) {
		logger = LoggerFactory.getLogger(VersionUtils.class);
	}
	return logger;
}
 
开发者ID:j256,项目名称:ormlite-core,代码行数:10,代码来源:VersionUtils.java

示例6: getLogger

import com.j256.ormlite.logger.LoggerFactory; //导入依赖的package包/类
private static Logger getLogger()
{
  if (logger == null)
    logger = LoggerFactory.getLogger(VersionUtils.class);
  return logger;
}
 
开发者ID:mmmsplay10,项目名称:QuizUpWinner,代码行数:7,代码来源:VersionUtils.java


注:本文中的com.j256.ormlite.logger.LoggerFactory类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。