本文整理了Java中org.jboss.logging.Logger.init()
方法的一些代码示例,展示了Logger.init()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Logger.init()
方法的具体详情如下:
包路径:org.jboss.logging.Logger
类名称:Logger
方法名:init
[英]Initialize the LoggerPlugin class to use as the delegate to the logging system. This first checks to see if a pluginClassName has been specified via the #setPluginClassName(String) method, then the PLUGIN_CLASS_PROP system property and finally the LOG4J_PLUGIN_CLASS_NAME default. If the LoggerPlugin implementation class cannot be loaded the default NullLoggerPlugin will be used.
[中]初始化LoggerPlugin类以用作日志系统的委托。首先检查是否通过#setPluginClassName(String)方法指定了pluginClassName,然后检查PLUGIN_CLASS_PROP系统属性,最后检查LOG4J_PLUGIN_CLASS_默认名称。如果无法加载LoggerPlugin实现类,则将使用默认的NullLoggerPlugin。
代码示例来源:origin: jboss.logging/jboss-logging-spi
/** Set the LoggerPlugin implementation class name in use
* @param pluginClassName the LoggerPlugin implementation class name
*/
public static void setPluginClassName(String pluginClassName)
{
if( pluginClassName.equals(Logger.pluginClassName) == false )
{
Logger.pluginClassName = pluginClassName;
init();
}
}
代码示例来源:origin: jboss/jboss-logging-spi
/**
* Set the LoggerPlugin implementation class name in use
*
* @param pluginClassName the LoggerPlugin implementation class name
*/
public static void setPluginClassName(String pluginClassName)
{
if (pluginClassName.equals(Logger.pluginClassName) == false)
{
Logger.pluginClassName = pluginClassName;
init();
}
}
代码示例来源:origin: org.jboss.logging/jboss-logging-spi
/**
* Set the LoggerPlugin implementation class name in use
*
* @param pluginClassName the LoggerPlugin implementation class name
*/
public static void setPluginClassName(String pluginClassName)
{
if (! pluginClassName.equals(Logger.pluginClassName))
{
Logger.pluginClassName = pluginClassName;
init();
}
}
代码示例来源:origin: org.jboss.logging/jboss-logging-spi
/**
* Custom serialization to reinitalize the delegate
*
* @param stream the object stream
* @throws IOException for any error
* @throws ClassNotFoundException if a class is not found during deserialization
*/
private void readObject(ObjectInputStream stream) throws IOException, ClassNotFoundException
{
// restore non-transient fields (aka name)
stream.defaultReadObject();
// Restore logging
if (pluginClass == null)
{
init();
}
}
代码示例来源:origin: jboss.logging/jboss-logging-spi
private void readObject(java.io.ObjectInputStream stream)
throws java.io.IOException, ClassNotFoundException
{
// restore non-transient fields (aka name)
stream.defaultReadObject();
// Restore logging
if (pluginClass == null)
{
init();
}
this.loggerDelegate = getDelegatePlugin(name);
}
代码示例来源:origin: jboss/jboss-logging-spi
/**
* Custom serialization to reinitalize the delegate
*
* @param stream the object stream
* @throws IOException for any error
* @throws ClassNotFoundException if a class is not found during deserialization
*/
private void readObject(ObjectInputStream stream) throws IOException, ClassNotFoundException
{
// restore non-transient fields (aka name)
stream.defaultReadObject();
// Restore logging
if (pluginClass == null)
{
init();
}
this.loggerDelegate = getDelegatePlugin(name);
}
内容来源于网络,如有侵权,请联系作者删除!