1 30 31 package de.susebox.java.lang; 32 33 import java.lang.IndexOutOfBoundsException ; 37 38 42 49 public class ExtIndexOutOfBoundsException 50 extends IndexOutOfBoundsException 51 implements ThrowableList 52 { 53 54 58 65 public Throwable getCause() { 66 return _next; 67 } 68 69 76 public Throwable nextThrowable() { 77 return getCause(); 78 } 79 80 87 public boolean isWrapper() { 88 return _isWrapper; 89 } 90 91 98 public String getFormat() { 99 return super.getMessage(); 100 } 101 102 109 public Object [] getArguments() { 110 return _args; 111 } 112 113 114 118 125 public ExtIndexOutOfBoundsException(String msg) { 126 this(null, msg, null); 127 } 128 129 143 public ExtIndexOutOfBoundsException(Throwable ex) { 144 this(ex, null, null); 145 } 146 147 163 public ExtIndexOutOfBoundsException(Throwable ex, String msg) { 164 this(ex, msg, null); 165 } 166 167 182 public ExtIndexOutOfBoundsException(String fmt, Object [] args) { 183 this(null, fmt, args); 184 } 185 186 197 public ExtIndexOutOfBoundsException(Throwable ex, String fmt, Object [] args) { 198 super(fmt); 199 200 if (ex != null && fmt == null) { 201 _isWrapper = true; 202 } else { 203 _isWrapper = false; 204 } 205 _next = ex; 206 _args = args; 207 } 208 209 210 214 222 public String getMessage() { 223 return ThrowableMessageFormatter.getMessage(this); 224 } 225 226 227 231 234 protected Object [] _args = null; 235 236 239 protected Throwable _next = null; 240 241 246 protected boolean _isWrapper = false; 247 } 248 | Popular Tags |