org.identityconnectors.common.logging.Log.<init>()方法的使用及代码示例

x33g5p2x  于2022-01-24 转载在 其他  
字(2.6k)|赞(0)|评价(0)|浏览(111)

本文整理了Java中org.identityconnectors.common.logging.Log.<init>()方法的一些代码示例,展示了Log.<init>()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Log.<init>()方法的具体详情如下:
包路径:org.identityconnectors.common.logging.Log
类名称:Log
方法名:<init>

Log.<init>介绍

[英]Create an instance of the log based on the SPI in the System properties.
[中]基于系统属性中的SPI创建日志实例。

代码示例

代码示例来源:origin: org.connid/framework

/**
 * Used for testing..
 */
static Log getLog(final Class<?> clazz, LogSpi logImpl) {
  return new Log(clazz, logImpl);
}

代码示例来源:origin: net.tirasa.connid/connector-framework

/**
 * Used for testing..
 */
static Log getLog(final Class<?> clazz, final LogSpi logImpl) {
  return new Log(clazz, logImpl);
}

代码示例来源:origin: Tirasa/ConnId

/**
 * Used for testing..
 */
static Log getLog(final Class<?> clazz, final LogSpi logImpl) {
  return new Log(clazz, logImpl);
}

代码示例来源:origin: Tirasa/ConnId

/**
 * Get the logger for the particular class. <code>
 * private static final Log LOG = Log.getLog(MyClass.class);
 * </code>
 *
 * @param clazz
 *            class to log information about.
 * @return logger to use for logging.
 */
public static Log getLog(final Class<?> clazz) {
  try {
    // check that we're not logging ourselves
    if (LogSpi.class.isAssignableFrom(clazz)) {
      throw new IllegalArgumentException();
    }
    // attempt to get an instance..
    final LogSpi logImpl = (LogSpi) getSpiClass().newInstance();
    return new Log(clazz, logImpl);
  } catch (RuntimeException e) {
    throw e;
  } catch (Exception e) {
    throw new RuntimeException(e);
  }
}

代码示例来源:origin: org.connid/framework

/**
 * Get the logger for the particular class. <code>
 * private static final Log LOG = Log.getLog(MyClass.class);
 * </code>
 * 
 * @param clazz
 *            class to log information about.
 * @return logger to use for logging.
 */
public static Log getLog(final Class<?> clazz) {
  try {
    // check that we're not logging ourselves
    if (LogSpi.class.isAssignableFrom(clazz)) {
      throw new IllegalArgumentException();
    }
    // attempt to get an instance..
    LogSpi logImpl = (LogSpi) getSpiClass().newInstance();
    return new Log(clazz, logImpl);
  } catch (RuntimeException e) {
    throw e;
  } catch (Exception e) {
    throw new RuntimeException(e);
  }
}

代码示例来源:origin: net.tirasa.connid/connector-framework

/**
 * Get the logger for the particular class. <code>
 * private static final Log LOG = Log.getLog(MyClass.class);
 * </code>
 *
 * @param clazz
 *            class to log information about.
 * @return logger to use for logging.
 */
public static Log getLog(final Class<?> clazz) {
  try {
    // check that we're not logging ourselves
    if (LogSpi.class.isAssignableFrom(clazz)) {
      throw new IllegalArgumentException();
    }
    // attempt to get an instance..
    final LogSpi logImpl = (LogSpi) getSpiClass().newInstance();
    return new Log(clazz, logImpl);
  } catch (RuntimeException e) {
    throw e;
  } catch (Exception e) {
    throw new RuntimeException(e);
  }
}

相关文章