1 package org.hibernate; 3 4 10 11 public class InstantiationException extends HibernateException { 12 13 private final Class clazz; 14 15 public InstantiationException(String s, Class clazz, Throwable root) { 16 super(s, root); 17 this.clazz = clazz; 18 } 19 20 public InstantiationException(String s, Class clazz) { 21 super(s); 22 this.clazz = clazz; 23 } 24 25 public InstantiationException(String s, Class clazz, Exception e) { 26 super(s, e); 27 this.clazz = clazz; 28 } 29 30 public Class getPersistentClass() { 31 return clazz; 32 } 33 34 public String getMessage() { 35 return super.getMessage() + clazz.getName(); 36 } 37 38 } 39 40 41 42 43 44 45 | Popular Tags |