1 22 package org.jboss.util.deadlock; 23 24 40 public class ApplicationDeadlockException extends RuntimeException 41 { 42 protected boolean retry = false; 43 44 45 public ApplicationDeadlockException() 46 { 47 super(); 48 } 49 50 public ApplicationDeadlockException(String msg, boolean retry) 51 { 52 super(msg); 53 this.retry = retry; 54 } 55 56 public boolean retryable() 57 { 58 return retry; 59 } 60 61 62 65 public static ApplicationDeadlockException isADE(Throwable t) 66 { 67 while (t!=null) 68 { 69 if (t instanceof ApplicationDeadlockException) 70 { 71 return (ApplicationDeadlockException)t; 72 } 73 else 74 { 75 t = t.getCause(); 76 } 77 } 78 return null; 79 } 80 81 } 82 83 | Popular Tags |