热门标签 | HotTags
当前位置:  开发笔记 > 编程语言 > 正文

java.util.logging.ErrorManager.()方法的使用及代码示例

本文整理了Java中java.util.logging.ErrorManager.<init>()方法的一些代码示例,展示了ErrorManag

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

ErrorManager.介绍

[英]Constructs an instance of ErrorManager.
[中]构造ErrorManager的实例。

代码示例

代码示例来源:origin: robovm/robovm

/**
* Constructs a {@code Handler} object with a default error manager instance
* {@code ErrorManager}, the default encoding, and the default logging
* level {@code Level.ALL}. It has no filter and no formatter.
*/
protected Handler() {
this.errorMan = new ErrorManager();
this.level = DEFAULT_LEVEL;
this.encoding = null;
this.filter = null;
this.formatter = null;
this.prefix = this.getClass().getName();
}

代码示例来源:origin: com.sun.mail/javax.mail

/**
* Used to get or create the default ErrorManager used before init.
* @return the super error manager or a new ErrorManager.
* @since JavaMail 1.5.3
*/
private ErrorManager defaultErrorManager() {
ErrorManager em;
try { //Try to share the super error manager.
em = super.getErrorManager();
} catch (RuntimeException | LinkageError ignore) {
em = null;
}
//Don't assume that the super call is not null.
if (em == null) {
em = new ErrorManager();
}
return em;
}

代码示例来源:origin: camunda/camunda-bpm-platform

/**
* Used to get or create the default ErrorManager used before init.
* @return the super error manager or a new ErrorManager.
* @since JavaMail 1.5.3
*/
private ErrorManager defaultErrorManager() {
ErrorManager em;
try { //Try to share the super error manager.
em = super.getErrorManager();
} catch (final RuntimeException ignore) {
em = null;
} catch (final LinkageError ignore) {
em = null;
}
//Don't assume that the super call is not null.
if (em == null) {
em = new ErrorManager();
}
return em;
}

代码示例来源:origin: camunda/camunda-bpm-platform

setErrorManager(new ErrorManager());

代码示例来源:origin: jboss/jboss-common-logging-jdk

/**
* No argument constructor.
*/
public DOMConfigurator()
{
this(new ErrorManager());
}

代码示例来源:origin: jboss/jboss-logging-jdk

/**
* No argument constructor.
*/
public DOMConfigurator()
{
this(new ErrorManager());
}

代码示例来源:origin: org.jboss.logging/jboss-logging-jdk

/**
* No argument constructor.
*/
public DOMConfigurator()
{
this(new ErrorManager());
}

代码示例来源:origin: ibinti/bugvm

/**
* Constructs a {@code Handler} object with a default error manager instance
* {@code ErrorManager}, the default encoding, and the default logging
* level {@code Level.ALL}. It has no filter and no formatter.
*/
protected Handler() {
this.errorMan = new ErrorManager();
this.level = DEFAULT_LEVEL;
this.encoding = null;
this.filter = null;
this.formatter = null;
this.prefix = this.getClass().getName();
}

代码示例来源:origin: com.jtransc/jtransc-rt

protected Handler() {
this.errorMan = new ErrorManager();
this.level = DEFAULT_LEVEL;
this.encoding = null;
this.filter = null;
this.formatter = null;
this.prefix = this.getClass().getName();
}

代码示例来源:origin: MobiVM/robovm

/**
* Constructs a {@code Handler} object with a default error manager instance
* {@code ErrorManager}, the default encoding, and the default logging
* level {@code Level.ALL}. It has no filter and no formatter.
*/
protected Handler() {
this.errorMan = new ErrorManager();
this.level = DEFAULT_LEVEL;
this.encoding = null;
this.filter = null;
this.formatter = null;
this.prefix = this.getClass().getName();
}

代码示例来源:origin: FlexoVM/flexovm

/**
* Constructs a {@code Handler} object with a default error manager instance
* {@code ErrorManager}, the default encoding, and the default logging
* level {@code Level.ALL}. It has no filter and no formatter.
*/
protected Handler() {
this.errorMan = new ErrorManager();
this.level = DEFAULT_LEVEL;
this.encoding = null;
this.filter = null;
this.formatter = null;
this.prefix = this.getClass().getName();
}

代码示例来源:origin: com.mobidevelop.robovm/robovm-rt

/**
* Constructs a {@code Handler} object with a default error manager instance
* {@code ErrorManager}, the default encoding, and the default logging
* level {@code Level.ALL}. It has no filter and no formatter.
*/
protected Handler() {
this.errorMan = new ErrorManager();
this.level = DEFAULT_LEVEL;
this.encoding = null;
this.filter = null;
this.formatter = null;
this.prefix = this.getClass().getName();
}

代码示例来源:origin: com.bugvm/bugvm-rt

/**
* Constructs a {@code Handler} object with a default error manager instance
* {@code ErrorManager}, the default encoding, and the default logging
* level {@code Level.ALL}. It has no filter and no formatter.
*/
protected Handler() {
this.errorMan = new ErrorManager();
this.level = DEFAULT_LEVEL;
this.encoding = null;
this.filter = null;
this.formatter = null;
this.prefix = this.getClass().getName();
}

代码示例来源:origin: com.gluonhq/robovm-rt

/**
* Constructs a {@code Handler} object with a default error manager instance
* {@code ErrorManager}, the default encoding, and the default logging
* level {@code Level.ALL}. It has no filter and no formatter.
*/
protected Handler() {
this.errorMan = new ErrorManager();
this.level = DEFAULT_LEVEL;
this.encoding = null;
this.filter = null;
this.formatter = null;
this.prefix = this.getClass().getName();
}

代码示例来源:origin: xap/xap

private static Properties getVersionPropertiesFromFile(String path) {
Properties properties = new Properties();
try {
InputStream inputStream = PlatformVersion.class.getClassLoader().getResourceAsStream(path);
if (inputStream != null) {
properties.load(inputStream);
inputStream.close();
}
} catch (Throwable t) {
ErrorManager errorManager = new ErrorManager();
errorManager.error("Failed to load version properties from " + path, new Exception(t), ErrorManager.OPEN_FAILURE);
}
return properties;
}

代码示例来源:origin: jboss/jboss-javaee-specs

/**
* Used to get or create the default ErrorManager used before init.
* @return the super error manager or a new ErrorManager.
* @since JavaMail 1.5.3
*/
private ErrorManager defaultErrorManager() {
ErrorManager em;
try { //Try to share the super error manager.
em = super.getErrorManager();
} catch (RuntimeException | LinkageError ignore) {
em = null;
}
//Don't assume that the super call is not null.
if (em == null) {
em = new ErrorManager();
}
return em;
}

代码示例来源:origin: com.sun.mail/jakarta.mail

/**
* Used to get or create the default ErrorManager used before init.
* @return the super error manager or a new ErrorManager.
* @since JavaMail 1.5.3
*/
private ErrorManager defaultErrorManager() {
ErrorManager em;
try { //Try to share the super error manager.
em = super.getErrorManager();
} catch (RuntimeException | LinkageError ignore) {
em = null;
}
//Don't assume that the super call is not null.
if (em == null) {
em = new ErrorManager();
}
return em;
}

代码示例来源:origin: org.glassfish.metro/webservices-extra

/**
* Used to get or create the default ErrorManager used before init.
* @return the super error manager or a new ErrorManager.
* @since JavaMail 1.5.3
*/
private ErrorManager defaultErrorManager() {
ErrorManager em;
try { //Try to share the super error manager.
em = super.getErrorManager();
} catch (RuntimeException | LinkageError ignore) {
em = null;
}
//Don't assume that the super call is not null.
if (em == null) {
em = new ErrorManager();
}
return em;
}

代码示例来源:origin: stackoverflow.com

Options optiOns= new Options("nashorn");
options.set("anon.functions", true);
options.set("parse.only", true);
options.set("scripting", true);
ErrorManager errors = new ErrorManager();
Context cOntext= new Context(options, errors, Thread.currentThread().getContextClassLoader());
Source source = new Source("test", "var a = 10; var b = a + 1;" +
"function someFunction() { return b + 1; } ");
Parser parser = new Parser(context.getEnv(), source, errors);
FunctionNode functiOnNode= parser.parse();
Block block = functionNode.getBody();
List statements = block.getStatements();

代码示例来源:origin: stackoverflow.com

public class LogFilter implements Filter {
private final ErrorManager error = new ErrorManager();
@Override
public boolean isLoggable(LogRecord record) {
try {
//Insert code.
return false;
} catch (RuntimeException re) {
error.error(new SimpleFormatter().format(record),
re, ErrorManager.GENERIC_FAILURE);
return true;
}
}

推荐阅读
  • 本文将详细探讨 Java 中提供的不可变集合(如 `Collections.unmodifiableXXX`)和同步集合(如 `Collections.synchronizedXXX`)的实现原理及使用方法,帮助开发者更好地理解和应用这些工具。 ... [详细]
  • 在尝试使用C# Windows Forms客户端通过SignalR连接到ASP.NET服务器时,遇到了内部服务器错误(500)。本文将详细探讨问题的原因及解决方案。 ... [详细]
  • 深入解析动态代理模式:23种设计模式之三
    在设计模式中,动态代理模式是应用最为广泛的一种代理模式。它允许我们在运行时动态创建代理对象,并在调用方法时进行增强处理。本文将详细介绍动态代理的实现机制及其应用场景。 ... [详细]
  • 深入解析 Android IPC 中的 Messenger 机制
    本文详细介绍了 Android 中基于消息传递的进程间通信(IPC)机制——Messenger。通过实例和源码分析,帮助开发者更好地理解和使用这一高效的通信工具。 ... [详细]
  • Java多线程实现:从1到100分段求和并汇总结果
    本文介绍如何使用Java编写一个程序,通过10个线程分别计算不同区间的和,并最终汇总所有线程的结果。每个线程负责计算一段连续的整数之和,最后将所有线程的结果相加。 ... [详细]
  • ListView简单使用
    先上效果:主要实现了Listview的绑定和点击事件。项目资源结构如下:先创建一个动物类,用来装载数据:Animal类如下:packagecom.example.simplelis ... [详细]
  • 本文详细探讨了Java中的ClassLoader类加载器的工作原理,包括其如何将class文件加载至JVM中,以及JVM启动时的动态加载策略。文章还介绍了JVM内置的三种类加载器及其工作方式,并解释了类加载器的继承关系和双亲委托机制。 ... [详细]
  • 本文旨在探讨如何利用决策树算法实现对男女性别的分类。通过引入信息熵和信息增益的概念,结合具体的数据集,详细介绍了决策树的构建过程,并展示了其在实际应用中的效果。 ... [详细]
  • 当unique验证运到图片上传时
    2019独角兽企业重金招聘Python工程师标准model:public$imageFile;publicfunctionrules(){return[[[na ... [详细]
  • 烤鸭|本文_Spring之Bean的生命周期详解
    烤鸭|本文_Spring之Bean的生命周期详解 ... [详细]
  • 本文探讨如何利用Java反射技术来模拟Webwork框架中的URL解析过程。通过这一实践,读者可以更好地理解Webwork及其后续版本Struts2的工作原理,尤其是它们在MVC架构下的角色。 ... [详细]
  • 利用YAML配置Resilience4J的Circuit Breaker
    本文探讨了Resilience4j作为现代Java应用程序中不可或缺的容错工具,特别介绍了如何通过YAML文件配置Circuit Breaker以提高服务的弹性和稳定性。 ... [详细]
  • Java 架构:深入理解 JDK 动态代理机制
    代理模式是 Java 中常用的设计模式之一,其核心在于代理类与委托类共享相同的接口。代理类主要用于为委托类提供预处理、过滤、转发及后处理等功能,以增强或改变原有功能的行为。 ... [详细]
  • 本文详细介绍了如何在现有的Android Studio项目中集成JNI(Java Native Interface),包括下载必要的NDK和构建工具,配置CMakeLists.txt文件,以及编写和调用JNI函数的具体步骤。 ... [详细]
  • 深入解析Java虚拟机(JVM)架构与原理
    本文旨在为读者提供对Java虚拟机(JVM)的全面理解,涵盖其主要组成部分、工作原理及其在不同平台上的实现。通过详细探讨JVM的结构和内部机制,帮助开发者更好地掌握Java编程的核心技术。 ... [详细]
author-avatar
印大大
这个家伙很懒,什么也没留下!
PHP1.CN | 中国最专业的PHP中文社区 | DevBox开发工具箱 | json解析格式化 |PHP资讯 | PHP教程 | 数据库技术 | 服务器技术 | 前端开发技术 | PHP框架 | 开发工具 | 在线工具
Copyright © 1998 - 2020 PHP1.CN. All Rights Reserved | 京公网安备 11010802041100号 | 京ICP备19059560号-4 | PHP1.CN 第一PHP社区 版权所有