程序包 org.hibernate
类 WrongClassException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- javax.persistence.PersistenceException
-
- org.hibernate.HibernateException
-
- org.hibernate.WrongClassException
-
- 所有已实现的接口:
Serializable
public class WrongClassException extends HibernateException
Thrown when loading an entity (by identifier) results in a value that cannot be treated as the subclass type requested by the caller.- 作者:
- Gavin King
- 另请参阅:
- 序列化表格
-
-
构造器概要
构造器 构造器 说明 WrongClassException(String message, Serializable identifier, String entityName)Constructs a WrongClassException using the supplied information.
-
方法概要
所有方法 实例方法 具体方法 修饰符和类型 方法 说明 StringgetEntityName()SerializablegetIdentifier()
-
-
-
构造器详细资料
-
WrongClassException
public WrongClassException(String message, Serializable identifier, String entityName)
Constructs a WrongClassException using the supplied information.- 参数:
message- A message explaining the exception conditionidentifier- The identifier of the entityentityName- The entity-type requested
-
-
方法详细资料
-
getEntityName
public String getEntityName()
-
getIdentifier
public Serializable getIdentifier()
-
-