com.sun.enterprise.deployment
Class ErrorPageDescriptor

java.lang.Object
  extended by com.sun.enterprise.deployment.ErrorPageDescriptor
All Implemented Interfaces:
java.io.Serializable

public class ErrorPageDescriptor
extends java.lang.Object
implements java.io.Serializable

Objects exhiniting this interface represent an error page and the exception type or error code that will cause the redirect from the web container.

Author:
Danny Coward
See Also:
Serialized Form

Constructor Summary
ErrorPageDescriptor()
          The default constructor.
ErrorPageDescriptor(int errorCode, java.lang.String location)
          Constructor for error code to error page mapping.
ErrorPageDescriptor(java.lang.String exceptionType, java.lang.String location)
          Constructor for Java exception type to error page mapping.
 
Method Summary
 int getErrorCode()
          Return the error code.
 java.lang.String getErrorSignifierAsString()
          If there is an exception type, then the exception type is returned.
 java.lang.String getExceptionType()
          Return the exception type or the empty string if none.
 java.lang.String getLocation()
          Return the page to map to
 void print(java.lang.StringBuffer toStringBuffer)
           
 void setErrorCode(int errorCode)
          Sets the error code.
 void setErrorSignifierAsString(java.lang.String errorSignifier)
          Sets the error code if the argument is parsable as an int, or the exception type else.
 void setExceptionType(java.lang.String exceptionType)
          Sets the exception type.
 void setLocation(java.lang.String location)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ErrorPageDescriptor

public ErrorPageDescriptor()
The default constructor.


ErrorPageDescriptor

public ErrorPageDescriptor(int errorCode,
                           java.lang.String location)
Constructor for error code to error page mapping.


ErrorPageDescriptor

public ErrorPageDescriptor(java.lang.String exceptionType,
                           java.lang.String location)
Constructor for Java exception type to error page mapping.

Method Detail

getErrorCode

public int getErrorCode()
Return the error code. -1 if none.


setErrorCode

public void setErrorCode(int errorCode)
Sets the error code.


getErrorSignifierAsString

public java.lang.String getErrorSignifierAsString()
If there is an exception type, then the exception type is returned. Otherwise, if the error code is not -1, then the error code is returned as a string. If the error code is -1, then nul is returned.


setErrorSignifierAsString

public void setErrorSignifierAsString(java.lang.String errorSignifier)
Sets the error code if the argument is parsable as an int, or the exception type else.


getExceptionType

public java.lang.String getExceptionType()
Return the exception type or the empty string if none.


setExceptionType

public void setExceptionType(java.lang.String exceptionType)
Sets the exception type.


getLocation

public java.lang.String getLocation()
Return the page to map to


setLocation

public void setLocation(java.lang.String location)

print

public void print(java.lang.StringBuffer toStringBuffer)


Copyright © 2012 GlassFish Community. All Rights Reserved.