org.ow2.opensuit.core.error
Class IError

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by org.ow2.opensuit.core.error.IError
All Implemented Interfaces:
java.io.Serializable
Direct Known Subclasses:
LocalizedError, NonLocalizedError

public abstract class IError
extends java.lang.Exception

This abstract class represents the base error that open SUIT can handle in a nice way. That is: - display localized messages, - redirect the user to a specific view point after he has acknowledged the error

See Also:
Serialized Form

Field Summary
static short FUNCTIONAL_ERROR
          Error type: functional A functional error will lead to display a message box styled page
static short TECHNICAL_ERROR
          Error type: technical A technical error will lead to display an error box styled page (with complete stack trace).
 
Constructor Summary
IError(java.lang.String message)
           
IError(java.lang.String message, java.lang.Throwable cause)
           
 
Method Summary
abstract  java.lang.String getMessage(javax.servlet.http.HttpServletRequest iRequest)
           
abstract  java.lang.String getNextUrl()
           
abstract  java.lang.String getTitle(javax.servlet.http.HttpServletRequest iRequest)
           
 short getType()
           
 void setType(short type)
          Defines the error type (functional or technical).
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

FUNCTIONAL_ERROR

public static final short FUNCTIONAL_ERROR
Error type: functional A functional error will lead to display a message box styled page

See Also:
Constant Field Values

TECHNICAL_ERROR

public static final short TECHNICAL_ERROR
Error type: technical A technical error will lead to display an error box styled page (with complete stack trace).

See Also:
Constant Field Values
Constructor Detail

IError

public IError(java.lang.String message)

IError

public IError(java.lang.String message,
              java.lang.Throwable cause)
Method Detail

getTitle

public abstract java.lang.String getTitle(javax.servlet.http.HttpServletRequest iRequest)

getMessage

public abstract java.lang.String getMessage(javax.servlet.http.HttpServletRequest iRequest)

getNextUrl

public abstract java.lang.String getNextUrl()

getType

public short getType()

setType

public void setType(short type)
Defines the error type (functional or technical). A functional error will lead to display a message box styled page, whereas a technical one will display an error box (with the complete stack trace). By default, an error is technical.



Copyright © 2008-2012 OW2 Consortium. All Rights Reserved.