|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| SimpleFallbackExceptionHandler | Line # 32 | 1 | 0% | 1 | 0 | 100% |
1.0
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||
| No Tests | |||
| 1 | /* | |
| 2 | * Created on Jul 20, 2008 | |
| 3 | * | |
| 4 | * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except | |
| 5 | * in compliance with the License. You may obtain a copy of the License at | |
| 6 | * | |
| 7 | * http://www.apache.org/licenses/LICENSE-2.0 | |
| 8 | * | |
| 9 | * Unless required by applicable law or agreed to in writing, software distributed under the License | |
| 10 | * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express | |
| 11 | * or implied. See the License for the specific language governing permissions and limitations under | |
| 12 | * the License. | |
| 13 | * | |
| 14 | * Copyright @2008-2010 the original author or authors. | |
| 15 | */ | |
| 16 | package org.fest.swing.core; | |
| 17 | ||
| 18 | /** | |
| 19 | * Understands an exception handler for AWT event thread, to make sure we can get a back-trace dump when running | |
| 20 | * FEST-Swing are terminated by a <code>{@link EmergencyAbortListener}</code>. | |
| 21 | * <p> | |
| 22 | * This exception handler is passed to the JVM using the system property "sun.awt.exception.handler" to override the | |
| 23 | * default exception handling behavior of the event dispatch thread. | |
| 24 | * </p> | |
| 25 | * <p> | |
| 26 | * This is a Sun-specific feature (or "bug".) See <a | |
| 27 | * href="http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=4714232" target="_blank">bug 4714232</a>. | |
| 28 | * </p> | |
| 29 | * | |
| 30 | * @author <a href="mailto:simeon.fitch@mseedsoft.com">Simeon H.K. Fitch</a> | |
| 31 | */ | |
| 32 | public class SimpleFallbackExceptionHandler { | |
| 33 | ||
| 34 | /** | |
| 35 | * Prints the stack trace of the given exception to the standard error stream. | |
| 36 | * @param t the given exception. | |
| 37 | */ | |
| 38 | 1 |
public void handle(Throwable t) { |
| 39 | 1 | t.printStackTrace(); |
| 40 | } | |
| 41 | } | |
|
||||||||||||