• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

Java LogLevel类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

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



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

示例1: log

import org.apache.mina.filter.logging.LogLevel; //导入依赖的package包/类
protected void log ( final LogLevel level, final String message, final Object... args )
{
    switch ( level )
    {
        case DEBUG:
            this.logger.debug ( message, args );
            break;
        case INFO:
            this.logger.info ( message, args );
            break;
        case WARN:
            this.logger.warn ( message, args );
            break;
        case ERROR:
            this.logger.error ( message, args );
            break;
        case TRACE:
            this.logger.trace ( message, args );
            break;
        default:
            break;
    }
}
 
开发者ID:eclipse,项目名称:neoscada,代码行数:24,代码来源:FilterChainBuilder.java


示例2: log

import org.apache.mina.filter.logging.LogLevel; //导入依赖的package包/类
/**
 * Log if the logger and the current event log level are compatible. We log
 * a message and an exception.
 *
 * @param eventLevel the event log level as requested by the user
 * @param message    the message to log
 * @param cause      the exception cause to log
 */
private void log(LogLevel eventLevel, String message, Throwable cause) {
    switch (eventLevel) {
        case TRACE:
            logger.trace(message, cause);
            return;
        case DEBUG:
            logger.debug(message, cause);
            return;
        case INFO:
            logger.info(message, cause);
            return;
        case WARN:
            logger.warn(message, cause);
            return;
        case ERROR:
            logger.error(message, cause);
            return;
        default:
            return;
    }
}
 
开发者ID:WenZuHuai,项目名称:light-task-scheduler,代码行数:30,代码来源:MinaLogger.java


示例3: start

import org.apache.mina.filter.logging.LogLevel; //导入依赖的package包/类
public void start()
{
	mAcceptor = new NioSocketAcceptor();
	LoggingFilter loggingFilter = new LoggingFilter();
	loggingFilter.setSessionClosedLogLevel(LogLevel.NONE);
	loggingFilter.setSessionCreatedLogLevel(LogLevel.NONE);
	loggingFilter.setSessionOpenedLogLevel(LogLevel.NONE);
	loggingFilter.setMessageSentLogLevel(LogLevel.NONE);
	mAcceptor.getFilterChain().addLast("logger", loggingFilter);
	
	mAcceptor.getFilterChain().addLast("codec", new ProtocolCodecFilter(new MinaCodec.Encoder(), new MinaCodec.Decoder()));
	mAcceptor.getSessionConfig().setReadBufferSize(4096);
	// macceptor.getSessionConfig().setIdleTime(IdleStatus.BOTH_IDLE, 10);
	mServerHandler = new MinaServerHandler();
	mAcceptor.setHandler(mServerHandler);
	
	try {
		mAcceptor.bind(new InetSocketAddress(ServerConfig.NET_TCP_IP, ServerConfig.NET_TCP_PORT));
	} catch (IOException e) {
		// TODO Auto-generated catch block
		e.printStackTrace();
	}
}
 
开发者ID:AlkaidFang,项目名称:PearlHarbor,代码行数:24,代码来源:TCPConnectionClasser_mina.java


示例4: log

import org.apache.mina.filter.logging.LogLevel; //导入依赖的package包/类
/**
 * Copied by parent
 */
private void log(LogLevel eventLevel, String message, Object param) {
    switch (eventLevel) {
        case TRACE:
            log.trace(message, param);
            return;
        case DEBUG:
            log.debug(message, param);
            return;
        case INFO:
            log.info(message, param);
            return;
        case WARN:
            log.warn(message, param);
            return;
        case ERROR:
            log.error(message, param);
            return;
        default:
            return;
    }
}
 
开发者ID:milliondreams,项目名称:moquette-mqtt,代码行数:25,代码来源:MQTTLoggingFilter.java


示例5: getFilter

import org.apache.mina.filter.logging.LogLevel; //导入依赖的package包/类
public static LoggingFilter getFilter()
{
	LoggingFilter filter = new LoggingFilter();
	filter.setSessionCreatedLogLevel(LogLevel.NONE);
	filter.setSessionOpenedLogLevel(LogLevel.NONE);
	filter.setMessageReceivedLogLevel(LogLevel.NONE);
	filter.setSessionIdleLogLevel(LogLevel.NONE);
	filter.setSessionClosedLogLevel(LogLevel.NONE);
	filter.setMessageSentLogLevel(LogLevel.NONE);
	return filter;
}
 
开发者ID:apolaskey,项目名称:Falnir,代码行数:12,代码来源:MudConfig.java


示例6: setExceptionCaughtLogLevel

import org.apache.mina.filter.logging.LogLevel; //导入依赖的package包/类
/**
 * Set the LogLevel for the ExceptionCaught event.
 *
 * @param level The LogLevel to set
 */
public void setExceptionCaughtLogLevel(LogLevel level) {
    exceptionCaughtLevel = level;
}
 
开发者ID:WenZuHuai,项目名称:light-task-scheduler,代码行数:9,代码来源:MinaLogger.java


示例7: getExceptionCaughtLogLevel

import org.apache.mina.filter.logging.LogLevel; //导入依赖的package包/类
/**
 * Get the LogLevel for the ExceptionCaught event.
 *
 * @return The LogLevel for the ExceptionCaught eventType
 */
public LogLevel getExceptionCaughtLogLevel() {
    return exceptionCaughtLevel;
}
 
开发者ID:WenZuHuai,项目名称:light-task-scheduler,代码行数:9,代码来源:MinaLogger.java


示例8: setMessageReceivedLogLevel

import org.apache.mina.filter.logging.LogLevel; //导入依赖的package包/类
/**
 * Set the LogLevel for the MessageReceived event.
 *
 * @param level The LogLevel to set
 */
public void setMessageReceivedLogLevel(LogLevel level) {
    messageReceivedLevel = level;
}
 
开发者ID:WenZuHuai,项目名称:light-task-scheduler,代码行数:9,代码来源:MinaLogger.java


示例9: getMessageReceivedLogLevel

import org.apache.mina.filter.logging.LogLevel; //导入依赖的package包/类
/**
 * Get the LogLevel for the MessageReceived event.
 *
 * @return The LogLevel for the MessageReceived eventType
 */
public LogLevel getMessageReceivedLogLevel() {
    return messageReceivedLevel;
}
 
开发者ID:WenZuHuai,项目名称:light-task-scheduler,代码行数:9,代码来源:MinaLogger.java


示例10: setMessageSentLogLevel

import org.apache.mina.filter.logging.LogLevel; //导入依赖的package包/类
/**
 * Set the LogLevel for the MessageSent event.
 *
 * @param level The LogLevel to set
 */
public void setMessageSentLogLevel(LogLevel level) {
    messageSentLevel = level;
}
 
开发者ID:WenZuHuai,项目名称:light-task-scheduler,代码行数:9,代码来源:MinaLogger.java


示例11: getMessageSentLogLevel

import org.apache.mina.filter.logging.LogLevel; //导入依赖的package包/类
/**
 * Get the LogLevel for the MessageSent event.
 *
 * @return The LogLevel for the MessageSent eventType
 */
public LogLevel getMessageSentLogLevel() {
    return messageSentLevel;
}
 
开发者ID:WenZuHuai,项目名称:light-task-scheduler,代码行数:9,代码来源:MinaLogger.java


示例12: setSessionCreatedLogLevel

import org.apache.mina.filter.logging.LogLevel; //导入依赖的package包/类
/**
 * Set the LogLevel for the SessionCreated event.
 *
 * @param level The LogLevel to set
 */
public void setSessionCreatedLogLevel(LogLevel level) {
    sessionCreatedLevel = level;
}
 
开发者ID:WenZuHuai,项目名称:light-task-scheduler,代码行数:9,代码来源:MinaLogger.java


示例13: getSessionCreatedLogLevel

import org.apache.mina.filter.logging.LogLevel; //导入依赖的package包/类
/**
 * Get the LogLevel for the SessionCreated event.
 *
 * @return The LogLevel for the SessionCreated eventType
 */
public LogLevel getSessionCreatedLogLevel() {
    return sessionCreatedLevel;
}
 
开发者ID:WenZuHuai,项目名称:light-task-scheduler,代码行数:9,代码来源:MinaLogger.java


示例14: setSessionOpenedLogLevel

import org.apache.mina.filter.logging.LogLevel; //导入依赖的package包/类
/**
 * Set the LogLevel for the SessionOpened event.
 *
 * @param level The LogLevel to set
 */
public void setSessionOpenedLogLevel(LogLevel level) {
    sessionOpenedLevel = level;
}
 
开发者ID:WenZuHuai,项目名称:light-task-scheduler,代码行数:9,代码来源:MinaLogger.java


示例15: getSessionOpenedLogLevel

import org.apache.mina.filter.logging.LogLevel; //导入依赖的package包/类
/**
 * Get the LogLevel for the SessionOpened event.
 *
 * @return The LogLevel for the SessionOpened eventType
 */
public LogLevel getSessionOpenedLogLevel() {
    return sessionOpenedLevel;
}
 
开发者ID:WenZuHuai,项目名称:light-task-scheduler,代码行数:9,代码来源:MinaLogger.java


示例16: setSessionIdleLogLevel

import org.apache.mina.filter.logging.LogLevel; //导入依赖的package包/类
/**
 * Set the LogLevel for the SessionIdle event.
 *
 * @param level The LogLevel to set
 */
public void setSessionIdleLogLevel(LogLevel level) {
    sessionIdleLevel = level;
}
 
开发者ID:WenZuHuai,项目名称:light-task-scheduler,代码行数:9,代码来源:MinaLogger.java


示例17: getSessionIdleLogLevel

import org.apache.mina.filter.logging.LogLevel; //导入依赖的package包/类
/**
 * Get the LogLevel for the SessionIdle event.
 *
 * @return The LogLevel for the SessionIdle eventType
 */
public LogLevel getSessionIdleLogLevel() {
    return sessionIdleLevel;
}
 
开发者ID:WenZuHuai,项目名称:light-task-scheduler,代码行数:9,代码来源:MinaLogger.java


示例18: setSessionClosedLogLevel

import org.apache.mina.filter.logging.LogLevel; //导入依赖的package包/类
/**
 * Set the LogLevel for the SessionClosed event.
 *
 * @param level The LogLevel to set
 */
public void setSessionClosedLogLevel(LogLevel level) {
    sessionClosedLevel = level;
}
 
开发者ID:WenZuHuai,项目名称:light-task-scheduler,代码行数:9,代码来源:MinaLogger.java


示例19: getSessionClosedLogLevel

import org.apache.mina.filter.logging.LogLevel; //导入依赖的package包/类
/**
 * Get the LogLevel for the SessionClosed event.
 *
 * @return The LogLevel for the SessionClosed eventType
 */
public LogLevel getSessionClosedLogLevel() {
    return sessionClosedLevel;
}
 
开发者ID:WenZuHuai,项目名称:light-task-scheduler,代码行数:9,代码来源:MinaLogger.java



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


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
Java ColumnMetadata类代码示例发布时间:2022-05-22
下一篇:
Java EventClient类代码示例发布时间:2022-05-22
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap