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


Java Logger.getLogger方法代码示例

本文整理汇总了Java中com.hazelcast.logging.Logger.getLogger方法的典型用法代码示例。如果您正苦于以下问题:Java Logger.getLogger方法的具体用法?Java Logger.getLogger怎么用?Java Logger.getLogger使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在com.hazelcast.logging.Logger的用法示例。


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

示例1: getLogger

import com.hazelcast.logging.Logger; //导入方法依赖的package包/类
@Override
public final ILogger getLogger() {
    final String name = getClass().getName();
    try {
        return instance.getLoggingService().getLogger(name);
    } catch (UnsupportedOperationException e) {
        // HazelcastInstance is instance of HazelcastClient.
        return Logger.getLogger(name);
    }
}
 
开发者ID:hazelcast,项目名称:hazelcast-hibernate5,代码行数:11,代码来源:AbstractHazelcastRegion.java

示例2: setUp

import com.hazelcast.logging.Logger; //导入方法依赖的package包/类
@Before
public void setUp() {
    ILogger log = Logger.getLogger(ReadWriteAccessDelegateTest.class);

    cache = mock(RegionCache.class);

    HazelcastRegion region = mock(HazelcastRegion.class);
    when(region.getLogger()).thenReturn(log);
    when(region.getCache()).thenReturn(cache);

    delegate = new ReadWriteAccessDelegate<HazelcastRegion>(region, null);
}
 
开发者ID:hazelcast,项目名称:hazelcast-hibernate5,代码行数:13,代码来源:ReadWriteAccessDelegateTest.java

示例3: getLogger

import com.hazelcast.logging.Logger; //导入方法依赖的package包/类
public final ILogger getLogger() {
    final String name = getClass().getName();
    try {
        return instance.getLoggingService().getLogger(name);
    } catch (UnsupportedOperationException e) {
        // HazelcastInstance is instance of HazelcastClient.
        return Logger.getLogger(name);
    }
}
 
开发者ID:hazelcast,项目名称:hazelcast-hibernate,代码行数:10,代码来源:AbstractHazelcastRegion.java

示例4: tracer

import com.hazelcast.logging.Logger; //导入方法依赖的package包/类
public static Tracer tracer(Class<?> type) {
    if (!SnowcastConstants.LOGGING_ENABLED) {
        return NO_OP_TRACER;
    }
    ILogger logger = Logger.getLogger(type);
    return new TracerImpl(logger);
}
 
开发者ID:noctarius,项目名称:snowcast,代码行数:8,代码来源:TracingUtils.java

示例5: getHazelcastInstanceThreadContext

import com.hazelcast.logging.Logger; //导入方法依赖的package包/类
public HazelcastInstanceThreadContext getHazelcastInstanceThreadContext(FactoryImpl factory) {
    if (factory == null) {
        ILogger logger = Logger.getLogger(ThreadContext.class.getName());
        logger.log(Level.SEVERE, "Factory is null", new Throwable());
    }
    HazelcastInstanceThreadContext hic = mapHazelcastInstanceContexts.get(factory);
    if (hic != null) return hic;
    hic = new HazelcastInstanceThreadContext(factory);
    mapHazelcastInstanceContexts.put(factory, hic);
    return hic;
}
 
开发者ID:mdogan,项目名称:hazelcast-archive,代码行数:12,代码来源:ThreadContext.java

示例6: createLogger

import com.hazelcast.logging.Logger; //导入方法依赖的package包/类
private ILogger createLogger(final String name, final HazelcastInstance hazelcastInstance) {
    try {
        return hazelcastInstance.getLoggingService().getLogger(name);
    } catch (UnsupportedOperationException e) {
        return Logger.getLogger(name);
    }
}
 
开发者ID:health-and-care-developer-network,项目名称:health-and-care-developer-network,代码行数:8,代码来源:IMapRegionCache.java

示例7: JoinInfo

import com.hazelcast.logging.Logger; //导入方法依赖的package包/类
public JoinInfo() {
    this.logger = Logger.getLogger(JoinInfo.class.getName());
}
 
开发者ID:mdogan,项目名称:hazelcast-archive,代码行数:4,代码来源:JoinInfo.java

示例8: AddressPicker

import com.hazelcast.logging.Logger; //导入方法依赖的package包/类
public AddressPicker(Node node, ServerSocketChannel serverSocketChannel) {
    this.node = node;
    this.logger = Logger.getLogger(AddressPicker.class.getName());
    this.serverSocketChannel = serverSocketChannel;
}
 
开发者ID:mdogan,项目名称:hazelcast-archive,代码行数:6,代码来源:AddressPicker.java

示例9: AddressPicker

import com.hazelcast.logging.Logger; //导入方法依赖的package包/类
public AddressPicker(Node node) {
    this.node = node;
    this.logger = Logger.getLogger(AddressPicker.class.getName());
}
 
开发者ID:health-and-care-developer-network,项目名称:health-and-care-developer-network,代码行数:5,代码来源:AddressPicker.java


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