com.sas.sasserver
Class RemoteObjectSelectorDialog

com.sas.sasserver.RemoteObjectSelectorDialog
All Implemented Interfaces:
ContainerInterface, VisualInterface, com.sas.beans.PropertyChangeSource, com.sas.beans.VetoableChangeSource, com.sas.ComponentInterface, com.sas.DesignTimeDropTargetInterface, com.sas.lang.StringDataInterface, com.sas.LinkPropertiesInterface, com.sas.ModelInterface, ValidatorInterface, com.sas.ViewInterface, MultipleValueEventSourceInterface, java.awt.event.ActionListener, java.awt.event.WindowListener, java.awt.image.ImageObserver, java.awt.MenuContainer, java.beans.PropertyChangeListener, java.io.ObjectInputValidation, java.io.Serializable, java.util.EventListener, javax.accessibility.Accessible
Direct Known Subclasses:
CatalogSelectorDialog, DataSetSelectorDialog, EISSelectorDialog, LibrarySelectorDialog, MetabaseSelectorDialog

public abstract class RemoteObjectSelectorDialog

RemoteObjectSelector is a class that can serve as the base class of of a dialog that needs to create a connection to create remote objects. A dialog with an informational message is displayed while the createRemoteObjects method is run asynchronously.

See Also:
Serialized Form

Field Summary
protected  com.sas.rmi.Connection connection
          Connection object for remote access.
protected  java.awt.Component owner
          The owner of the RemoteObjectSelectorDialog.
protected  com.sas.collection.OrderedCollection remoteObjects
          Registered RemoteBaseClient objects.
protected  com.sas.rmi.Rocf rocf
          Rocf object used for remote object creation.
 
Fields inherited from class com.sas.visuals.OkCancelHelpDialog
CANCEL, CLOSE, HELP
 
Fields inherited from class com.sas.visuals.ButtonDialog
buttonPanel, buttons, panel
 
Fields inherited from class com.sas.awt.Dialog
_cantUseSASModal, _inApplet, _modal, autoDispose, READY, setVisibleCalled, t
 
Constructor Summary
RemoteObjectSelectorDialog(java.awt.Frame parent, java.awt.Component owner, com.sas.rmi.Connection connection, boolean cloneConnection, com.sas.rmi.Rocf rocf, java.lang.String title)
          Abstract class.
RemoteObjectSelectorDialog(java.awt.Frame parent, java.awt.Component owner, com.sas.rmi.Connection connection, com.sas.rmi.Rocf rocf, java.lang.String title)
          Abstract class.
 
Method Summary
protected  void createRemoteObjects()
          Creates an instance of Rocf.
 void dispose()
          Called whenever the dialog is being destroyed.
protected  void disposeRemoteObjects()
          Cleans up created remote objects.
 void initialize()
          Initializes the RemoteObjectSelectorDialog.
protected  void registerRemoteBaseClient(com.sas.rmi.RemoteBaseClient rbc)
          Registers a RemoteBaseClient.
 void setVisible(boolean newValue)
          Sets the dialog visible.
 boolean wasCancelled()
          Indicates whether or not the cancel button was pressed.
 boolean wasExceptionThrown()
          Indicates whether or not an exception was thrown creating the remote objects.
 
Methods inherited from class com.sas.visuals.OkCancelHelpDialog
actionPerformed, cancel, close, help, isValidateBeforeClosing, setValidateBeforeClosing, windowClosing
 
Methods inherited from class com.sas.visuals.ButtonDialog
getButtonPanel, getMainPanel, windowActivated, windowClosed, windowDeactivated, windowDeiconified, windowIconified, windowOpened
 
Methods inherited from class com.sas.awt.Dialog
center, centerOver, centerOverWindow, fireReadySignal, getAutoDispose, getDefaultHeight, getDefaultWidth, getExtendedBeanInfo, getText, hide, isSASModalEnabled, newDispatchThread, processWindowEvent, setAutoDispose, setDefaultHeight, setDefaultWidth, setModal, setResizable, setSASModalEnabled, setText, setTitle, setVisible, show, stopDispatchThread, waitForReadySignal, waitTilReady
 
Methods inherited from class com.sas.awt.DialogContainerComponent
addNotify, clone, dragEnter, dragLeave, dragOver, drop, getContainerInterfaceSupportInfo, getErrorHandler, getInsets, getValidator, isIDEDnDDropBarrier, isIDEDnDDropTarget, isValid, removeNotify, setContainerInterfaceSupportInfo, setDefaultValues, setErrorHandler, setIDEDnDDropBarrier, setIDEDnDDropTarget, setInsets, setInsets, setValidator, superAddNotify, superGetInsets, superRemoveNotify, superSetDefaultValues
 
Methods inherited from class com.sas.awt.DialogVisualComponent
addLink, addPropertyChangeListener, addVetoableChangeListener, anyPropertyChangeListeners, attachModel, attachView, computePreferredSize, detachModel, detachView, dumpComponent, firePropertyChange, firePropertyChange, fireVetoableChange, getBackgroundColor, getBorder, getComponentDescription, getComponentSupportInfo, getEventMethod, getEventValues, getFont, getForegroundColor, getHeight, getHorizontalPosition, getLinkInfo, getMinimumSize, getModelInterface, getPreferredSize, getPrePainter, getRequiredInterfaces, getVerticalPosition, getViewInterfaceSupportInfo, getVisualInterfaceSupportInfo, getWidth, initializeComponent, isDesignTime, isEnabled, isFocus, isLinked, isTransparent, isVisible, paint, propertyChange, queryLinks, queryLinks, refresh, removeAllLinks, removeInterfaceTraps, removeLink, removePropertyChangeListener, removeVetoableChangeListener, setBackgroundColor, setBorder, setBounds, setComponentDescription, setComponentSupportInfo, setEnabled, setFocus, setFont, setForegroundColor, setHeight, setHorizontalPosition, setLinkInfo, setModelInterface, setPreferredSize, setPrePainter, setRequiredInterfaces, setTransparent, setVerticalPosition, setViewInterfaceSupportInfo, setVisualInterfaceSupportInfo, setWidth, superGetFont, superGetMinimumSize, superGetPreferredSize, superIsEnabled, superIsVisible, superPaint, superSetBounds, superSetEnabled, superSetFont, superSetVisible, superUpdate, supportsListenerInterface, supportsRequiredInterfaces, trapInterfaceEvents, update, validateObject
 
Methods inherited from interface com.sas.awt.ContainerInterface
getComponents, getLayout, invalidate, setLayout, validate
 
Methods inherited from interface com.sas.awt.VisualInterface
computePreferredSize, getBackgroundColor, getBorder, getFont, getForegroundColor, getHeight, getHorizontalPosition, getMinimumSize, getPreferredSize, getPrePainter, getVerticalPosition, getVisualInterfaceSupportInfo, getWidth, isEnabled, isFocus, isTransparent, isVisible, setBackgroundColor, setBorder, setBounds, setEnabled, setFocus, setFont, setForegroundColor, setHeight, setHorizontalPosition, setPreferredSize, setPrePainter, setTransparent, setVerticalPosition, setVisualInterfaceSupportInfo, setWidth, superGetFont, superGetMinimumSize, superGetPreferredSize, superIsEnabled, superIsVisible, superPaint, superSetBounds, superSetEnabled, superSetFont, superSetVisible, superUpdate
 

Field Detail

connection

protected com.sas.rmi.Connection connection
Connection object for remote access.


rocf

protected com.sas.rmi.Rocf rocf
Rocf object used for remote object creation.


owner

protected java.awt.Component owner
The owner of the RemoteObjectSelectorDialog.


remoteObjects

protected com.sas.collection.OrderedCollection remoteObjects
Registered RemoteBaseClient objects.

Constructor Detail

RemoteObjectSelectorDialog

public RemoteObjectSelectorDialog(java.awt.Frame parent,
                                  java.awt.Component owner,
                                  com.sas.rmi.Connection connection,
                                  com.sas.rmi.Rocf rocf,
                                  java.lang.String title)
Abstract class. Cannot be instantiated.

Parameters:
parent - parent frame of the dialog
owner - owner of the dialog (may also be the parent)
connection - the connection object
rocf - Rocf object used for remote object creation
title - the title of the dialog

RemoteObjectSelectorDialog

public RemoteObjectSelectorDialog(java.awt.Frame parent,
                                  java.awt.Component owner,
                                  com.sas.rmi.Connection connection,
                                  boolean cloneConnection,
                                  com.sas.rmi.Rocf rocf,
                                  java.lang.String title)
Abstract class. Cannot be instantiated.

Parameters:
parent - parent frame of the dialog
owner - owner of the dialog (may also be the parent)
connection - the connection object
rocf - Rocf object used for remote object creation
title - the title of the dialog
Method Detail

registerRemoteBaseClient

protected void registerRemoteBaseClient(com.sas.rmi.RemoteBaseClient rbc)
Registers a RemoteBaseClient. Any objects registered with this method will be stopped during the customizerClosing method.

Parameters:
rbc - object to register

initialize

public void initialize()
Initializes the RemoteObjectSelectorDialog. Starts the thread which calls the createRemoteObjects method to initiate the connection. This method must be call if the CommandProgress dialog is to be displayed.

Specified by:
initialize in interface com.sas.ComponentInterface
Overrides:
initialize in class DialogVisualComponent
See Also:
ComponentInterface.initialize()

dispose

public void dispose()
Called whenever the dialog is being destroyed. Calls disposeRemoteObjects to clean up any create remote objects.

Overrides:
dispose in class Dialog

disposeRemoteObjects

protected void disposeRemoteObjects()
Cleans up created remote objects. If any RemoteBaseClient clients were registered with registerRemoteBaseClient, they are all stopped in this method. Additionally if the rocf is not a user supplied rocf, it is stopped.


wasCancelled

public boolean wasCancelled()
Indicates whether or not the cancel button was pressed.

Overrides:
wasCancelled in class OkCancelHelpDialog
Returns:
true if the progress dialog was cancelled, false otherwise

wasExceptionThrown

public boolean wasExceptionThrown()
Indicates whether or not an exception was thrown creating the remote objects.

Returns:
true if the an exception was thrown creating the remote objects, false otherwise

setVisible

public void setVisible(boolean newValue)
Sets the dialog visible. If the progress dialog has been cancelled or if an exception was thrown then the dialog is not allowed to be visible.

Specified by:
setVisible in interface VisualInterface
Overrides:
setVisible in class OkCancelHelpDialog
Parameters:
newValue - true to set the dialog visible, false otherwise
See Also:
VisualInterface.setVisible(boolean)

createRemoteObjects

protected void createRemoteObjects()
                            throws java.lang.Exception
Creates an instance of Rocf. This method will be run in a separate thread. This should be overridden to perform and operations or object creations using the rocf and connection objects.

Throws:
java.lang.Exception



Copyright © 2009 SAS Institute Inc. All Rights Reserved.