|
Copyright © 2008 BEA Systems, Inc. All Rights Reserved | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjava.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
javax.ejb.EJBException
com.beasys.commerce.foundation.exception.SystemException
@Deprecated public class SystemException
The SystemException class is used to signal system-level exceptions
to a caller. It is the base system exception class. A system-level exception
is a severe exception that prevents a thread of execution from proceeding in a
normal manner.
The SystemException class is closely tied to the
MessageCatalog. An SystemException
contains a log and user message that is constructed using the MessageCatalog.
In fact, each SystemException derivative should have at
least one user and log catalog message.
In the case of an EJB, the following guidelines should be followed:
If an enterprise bean method encounters a system-level exception or error that does not allow the method to successfully complete, the method should throw a suitable system exception compatible with the method's throw clause:
RuntimeException or
error, it should simply propagate the error from the bean method to the Container.
SystemException or
derivative that wraps the original exception.
SystemException
or EJBException.
A bean provider is responsible for using the standard EJB system exceptions
(EJBException and NoSuchEntityException) where
appropriate.
Since the practice of throwing a RemoteException has been deprecated
in the EJB 1.1 specification, all such occurrences must be replaced with an
instance of SystemException. In the case of a bean method that calls
another bean method, all RemoteExceptions should simply be propagated
from the bean method.
If an EJB method throws a SystemException, any existing
transaction will be rolled back by the Container and the bean's state will
be set to "does not exists".
EJBException,
MessageCatalog,
MessageCatalogException,
Serialized Form| Field Summary | |
|---|---|
protected Stack |
logMessages
Deprecated See BEA Commerce product offering |
protected Stack |
userMessages
Deprecated See BEA Commerce product offering |
| Constructor Summary | |
|---|---|
SystemException()
Deprecated See BEA Commerce product offering |
|
SystemException(String namespace,
String messageKey)
Deprecated See BEA Commerce product offering |
|
SystemException(String namespace,
String messageKey,
Exception exception)
Deprecated See BEA Commerce product offering |
|
SystemException(String namespace,
String messageKey,
Object argument)
Deprecated See BEA Commerce product offering |
|
SystemException(String namespace,
String messageKey,
Object[] arguments)
Deprecated See BEA Commerce product offering |
|
SystemException(String namespace,
String messageKey,
Object[] arguments,
Exception exception)
Deprecated See BEA Commerce product offering |
|
SystemException(String namespace,
String messageKey,
Object argument,
Exception exception)
Deprecated See BEA Commerce product offering |
|
SystemException(SystemException topException,
SystemException bottomException)
Deprecated See BEA Commerce product offering |
|
| Method Summary | |
|---|---|
void |
addLogMessage(String namespace,
String messageKey)
Deprecated See BEA Commerce product offering |
void |
addLogMessage(String namespace,
String messageKey,
Object argument)
Deprecated See BEA Commerce product offering |
void |
addLogMessage(String namespace,
String messageKey,
Object[] arguments)
Deprecated See BEA Commerce product offering |
void |
addMessage(String namespace,
String messageKey)
Deprecated See BEA Commerce product offering |
void |
addMessage(String namespace,
String messageKey,
Object argument)
Deprecated See BEA Commerce product offering |
void |
addMessage(String namespace,
String messageKey,
Object[] arguments)
Deprecated See BEA Commerce product offering |
void |
addUserMessage(String namespace,
String messageKey)
Deprecated See BEA Commerce product offering |
void |
addUserMessage(String namespace,
String messageKey,
Object argument)
Deprecated See BEA Commerce product offering |
void |
addUserMessage(String namespace,
String messageKey,
Object[] arguments)
Deprecated See BEA Commerce product offering |
Exception |
getEmbeddedException()
Deprecated See BEA Commerce product offering |
String |
getLocalizedMessage()
Deprecated See BEA Commerce product offering |
String |
getLogMessage()
Deprecated See BEA Commerce product offering |
Iterator |
getLogMessages()
Deprecated See BEA Commerce product offering |
String |
getMessage()
Deprecated See BEA Commerce product offering |
String |
getUserMessage()
Deprecated See BEA Commerce product offering |
Iterator |
getUserMessages()
Deprecated See BEA Commerce product offering |
String |
toString()
Deprecated See BEA Commerce product offering |
| Methods inherited from class javax.ejb.EJBException |
|---|
getCausedByException, printStackTrace, printStackTrace, printStackTrace |
| Methods inherited from class java.lang.Throwable |
|---|
fillInStackTrace, getCause, getStackTrace, initCause, setStackTrace |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
protected Stack logMessages
protected Stack userMessages
| Constructor Detail |
|---|
public SystemException()
SystemException with no associated message.
public SystemException(SystemException topException,
SystemException bottomException)
SystemException from two source SystemExceptions
by concatinating the screen and log messages of the two source SystemExceptions.
The messages of the first SystemException will preceed those of the second in the
constructed SystemException. Furthermore, the new SystemException
will have the embedded exception of the first SystemException associated with it.
SystemException - topExceptionSystemException - bottomException
public SystemException(String namespace,
String messageKey)
namespace - The associated catalog message namespace.messageKey - The associated catalog message key.
public SystemException(String namespace,
String messageKey,
Exception exception)
namespace - The associated catalog message namespace.messageKey - The associated catalog message key.exception - The embedded exception.
public SystemException(String namespace,
String messageKey,
Object argument)
namespace - The associated catalog message namespace.messageKey - The associated catalog message key.argument - The message parameter substitution argument.
public SystemException(String namespace,
String messageKey,
Object argument,
Exception exception)
namespace - The associated catalog message namespace.messageKey - The associated catalog message key.argument - The message parameter substitution argument.exception - The embedded exception.
public SystemException(String namespace,
String messageKey,
Object[] arguments)
namespace - The associated catalog message namespace.messageKey - The associated catalog message key.arguments - The message parameter substitution arguments.
public SystemException(String namespace,
String messageKey,
Object[] arguments,
Exception exception)
namespace - The associated catalog message namespace.messageKey - The associated catalog message key.arguments - The message parameter substitution arguments.exception - The embedded exception.| Method Detail |
|---|
public Exception getEmbeddedException()
MessageCatalogException
getEmbeddedException in interface MessageCatalogExceptionpublic String getLogMessage()
MessageCatalogException
getLogMessage in interface MessageCatalogExceptionpublic Iterator getLogMessages()
MessageCatalogException
getLogMessages in interface MessageCatalogException
public void addLogMessage(String namespace,
String messageKey)
MessageCatalogException
addLogMessage in interface MessageCatalogExceptionnamespace - Log catalog message namespace.messageKey - Log catalog message key.
public void addLogMessage(String namespace,
String messageKey,
Object argument)
MessageCatalogException
addLogMessage in interface MessageCatalogExceptionnamespace - Log catalog message namespace.messageKey - Log catalog message key.argument - Message parameter substitution argument.
public void addLogMessage(String namespace,
String messageKey,
Object[] arguments)
MessageCatalogException
addLogMessage in interface MessageCatalogExceptionnamespace - Log catalog message namespace.messageKey - Log catalog message key.public String getUserMessage()
MessageCatalogException
getUserMessage in interface MessageCatalogExceptionpublic Iterator getUserMessages()
MessageCatalogException
getUserMessages in interface MessageCatalogException
public void addUserMessage(String namespace,
String messageKey)
MessageCatalogException
addUserMessage in interface MessageCatalogExceptionnamespace - User catalog message namespace.messageKey - User catalog message key.
public void addUserMessage(String namespace,
String messageKey,
Object argument)
MessageCatalogException
addUserMessage in interface MessageCatalogExceptionnamespace - User catalog message namespace.messageKey - User catalog message key.argument - Message parameter substitution argument.
public void addUserMessage(String namespace,
String messageKey,
Object[] arguments)
MessageCatalogException
addUserMessage in interface MessageCatalogExceptionnamespace - User catalog message namespace.messageKey - User catalog message key.
public void addMessage(String namespace,
String messageKey)
MessageCatalogException
addMessage in interface MessageCatalogExceptionnamespace - User and log catalog message namespace.messageKey - User and log catalog message key.
public void addMessage(String namespace,
String messageKey,
Object argument)
MessageCatalogException
addMessage in interface MessageCatalogExceptionnamespace - User and log catalog message namespace.messageKey - User and log catalog message key.argument - Message parameter substitution argument.
public void addMessage(String namespace,
String messageKey,
Object[] arguments)
MessageCatalogException
addMessage in interface MessageCatalogExceptionnamespace - User and log catalog message namespace.messageKey - User and log catalog message key.public String getMessage()
getMessage in class javax.ejb.EJBExceptionpublic String getLocalizedMessage()
getLocalizedMessage in class Throwablepublic String toString()
toString in class Throwable
|
Copyright © 2008 BEA Systems, Inc. All Rights Reserved | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||