Save This Page
Home » hibernate-entity-src-20081106 » javax » persistence » [javadoc | source]
javax.persistence
public class: PersistenceException [javadoc | source]
java.lang.Object
   java.lang.Throwable
      java.lang.Exception
         java.lang.RuntimeException
            javax.persistence.PersistenceException

All Implemented Interfaces:
    Serializable

Direct Known Subclasses:
    RollbackException, EntityExistsException, EntityNotFoundException, TransactionRequiredException, OptimisticLockException, NoResultException, NonUniqueResultException

Thrown by the persistence provider when a problem occurs. All instances of PersistenceException except for instances of NoResultException and NonUniqueResultException will cause the current transaction, if one is active, to be marked for rollback.
Constructor:
 public PersistenceException() 
 public PersistenceException(String message) 
    Constructs a new PersistenceException exception with the specified detail message.
    Parameters:
    message - the detail message
 public PersistenceException(Throwable cause) 
    Constructs a new PersistenceException exception with the specified cause
    Parameters:
    cause - the cause
 public PersistenceException(String message,
    Throwable cause) 
    Constructs a new PersistenceException exception with the specified detail message and cause
    Parameters:
    message - the detail message
    cause - the cause
Methods from java.lang.Throwable:
fillInStackTrace,   getCause,   getLocalizedMessage,   getMessage,   getStackTrace,   initCause,   printStackTrace,   printStackTrace,   printStackTrace,   setStackTrace,   toString
Methods from java.lang.Object:
equals,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait