Extension SDK 10.1.2

oracle.ide.panels
Class TraversalException

java.lang.Object
  extended byjava.lang.Throwable
      extended byjava.lang.Exception
          extended byoracle.ide.panels.TraversalException
All Implemented Interfaces:
java.io.Serializable

public class TraversalException
extends java.lang.Exception

The TraversalException can be thrown by the Traversable.onExit(TraversableContext) method if the user has entered incomplete, invalid, or inconsistent data that causes validation to fail.

An error message of some kind is required when instantiating the TraversalException. The message can be a regular String or it can be any object that is accepted by JOptionPane for its message area.

See Also:
Serialized Form

Constructor Summary
TraversalException(java.lang.Object message)
          Creates a new instance with the specified object providing the displayable error message UI to show to the user.
TraversalException(java.lang.Object message, java.lang.String title)
          Creates a new instance with the specified object providing the displayable error message UI to show to the user.
TraversalException(java.lang.Object message, java.lang.String title, java.lang.String helpID)
          Creates a new instance with the specified object providing the displayable error message UI to show to the user.
TraversalException(java.lang.String message)
          Creates a new instance with the specified String as the displayable error message to show to the user.
TraversalException(java.lang.String message, java.lang.String title)
          Creates a new instance with the specified String as the displayable error message to show to the user.
TraversalException(java.lang.String message, java.lang.String title, java.lang.String helpID)
          Creates a new instance with the specified String as the displayable error message to show to the user.
 
Method Summary
 void showMessageDialog(java.awt.Component parentComponent)
          Displays the message associated with this TraversalException in an alert and with the title set with the TraversalException in the constructor.
 
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
 

Constructor Detail

TraversalException

public TraversalException(java.lang.String message)
Creates a new instance with the specified String as the displayable error message to show to the user.

Parameters:
message - The error message to show to the user. If null, the TraversalException will not display a dialog when showMessageDialog(Component) is called.

TraversalException

public TraversalException(java.lang.String message,
                          java.lang.String title)
Creates a new instance with the specified String as the displayable error message to show to the user.

Parameters:
message - The error message to show to the user. If null, the TraversalException will not display a dialog when showMessageDialog(Component) is called.
title - The title used by the message dialog shown by showMessageDialog(Component).

TraversalException

public TraversalException(java.lang.String message,
                          java.lang.String title,
                          java.lang.String helpID)
Creates a new instance with the specified String as the displayable error message to show to the user.

Parameters:
message - The error message to show to the user. If null, the TraversalException will not display a dialog when showMessageDialog(Component) is called.
title - The title used by the message dialog shown by showMessageDialog(Component).
helpID - The help topic ID to be associated with the help button in the dialog shown by showMessageDialog(Component).

TraversalException

public TraversalException(java.lang.Object message)
Creates a new instance with the specified object providing the displayable error message UI to show to the user. Generally, the object should be a Component. If it is not a Component, then the object will be converted to a String before being displayed to the user.

Parameters:
message - The error message to show to the user. If it is a Component, then it is rendered in the message dialog; otherwise, it is converted to a String. If the message is null, the TraversalException will not display a dialog when the showMessageDialog(Component) method is called.

TraversalException

public TraversalException(java.lang.Object message,
                          java.lang.String title)
Creates a new instance with the specified object providing the displayable error message UI to show to the user. Generally, the object should be a Component. If it is not a Component, then the object will be converted to a String before being displayed to the user.

Parameters:
message - The error message to show to the user. If it is a Component, then it is rendered in the message dialog; otherwise, it is converted to a String. If the message is null, the TraversalException will not display a dialog when the showMessageDialog(Component) method is called.
title - The title used by the message dialog shown by showMessageDialog(Component).

TraversalException

public TraversalException(java.lang.Object message,
                          java.lang.String title,
                          java.lang.String helpID)
Creates a new instance with the specified object providing the displayable error message UI to show to the user. Generally, the object should be a Component. If it is not a Component, then the object will be converted to a String before being displayed to the user.

Parameters:
message - The error message to show to the user. If it is a Component, then it is rendered in the message dialog; otherwise, it is converted to a String. If the message is null, the TraversalException will not display a dialog when the showMessageDialog(Component) method is called.
title - The title used by the message dialog shown by showMessageDialog(Component).
helpID - The help topic ID to be associated with the help button in the dialog shown by showMessageDialog(Component).
Method Detail

showMessageDialog

public void showMessageDialog(java.awt.Component parentComponent)
Displays the message associated with this TraversalException in an alert and with the title set with the TraversalException in the constructor. The alert is parented onto the specified Component.

If the message set with this TraversalException is null, then this method returns without showing any UI. Therefore, the dialog is effectively skipped.


Extension SDK

 

Copyright © 1997, 2004, Oracle. All rights reserved.