Package javax.portlet
Class PortletModeException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- javax.portlet.PortletException
-
- javax.portlet.PortletModeException
-
- All Implemented Interfaces:
java.io.Serializable
public class PortletModeException extends PortletException
ThePortletModeException
is thrown when a portlet tries to use or set a portlet mode that is not supported by the current runtime environment or the portlet.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description private PortletMode
_mode
private static long
serialVersionUID
-
Constructor Summary
Constructors Constructor Description PortletModeException(java.lang.String text, java.lang.Throwable cause, PortletMode mode)
Constructs a new portlet mode exception when the portlet needs to do the following: throw an exception include a message about the "root cause" that interfered with its normal operation include a description message include the portlet mode that caused this exceptionPortletModeException(java.lang.String text, PortletMode mode)
Constructs a new portlet mode exception with the given text and the portlet mode that caused this exception.PortletModeException(java.lang.Throwable cause, PortletMode mode)
Constructs a new portlet mode exception when the portlet needs to throw an exception.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description PortletMode
getMode()
Returns the unsupported portlet mode causing this exception.
-
-
-
Field Detail
-
_mode
private transient PortletMode _mode
-
serialVersionUID
private static final long serialVersionUID
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
PortletModeException
public PortletModeException(java.lang.String text, PortletMode mode)
Constructs a new portlet mode exception with the given text and the portlet mode that caused this exception. The portlet container may use the text and portlet mode write it to a log.- Parameters:
text
- the exception textmode
- the mode causing the exception
-
PortletModeException
public PortletModeException(java.lang.String text, java.lang.Throwable cause, PortletMode mode)
Constructs a new portlet mode exception when the portlet needs to do the following:- throw an exception
- include a message about the "root cause" that interfered with its normal operation
- include a description message
- include the portlet mode that caused this exception
- Parameters:
text
- the exception textcause
- the root causemode
- the mode causing the exception
-
PortletModeException
public PortletModeException(java.lang.Throwable cause, PortletMode mode)
Constructs a new portlet mode exception when the portlet needs to throw an exception. The exception message is based on the localized message of the underlying exception and the portlet mode that caused this exception.- Parameters:
cause
- the root causemode
- the mode causing the exception
-
-
Method Detail
-
getMode
public PortletMode getMode()
Returns the unsupported portlet mode causing this exception.- Returns:
- the portlet mode that caused this exception
-
-