com.sas.swing.visuals.remotefileselector
Class RemoteFileNamePanel

com.sas.swing.visuals.remotefileselector.RemoteFileNamePanel
All Implemented Interfaces:
java.awt.image.ImageObserver, java.awt.MenuContainer, java.beans.PropertyChangeListener, java.io.Serializable, java.util.EventListener, javax.accessibility.Accessible

public class RemoteFileNamePanel
implements java.beans.PropertyChangeListener

RemoteFileNamePanel displays the selected file, the file type filtering component and the action buttons like OK, Save, Open, Cancel.

Since:
3.0
See Also:
Serialized Form

Constructor Summary
RemoteFileNamePanel(java.util.Map fileExtensions, javax.swing.JComponent parent)
          Constructor that allows setting of the file type extensions and the parent of this component.
 
Method Summary
 void addActionButtons(javax.swing.JButton action, javax.swing.JButton cancel)
          Allows setting of the action buttons.
 java.lang.String getFileName()
          Returns the item(s) that are currently displayed in the file name field.
 void propertyChange(java.beans.PropertyChangeEvent e)
          Listens for changes in the selections made on the table component.
 void setRemoteFileViewComponent(RemoteFileComponentInterface component)
          Sets the view component (i.e. table view) so that listener communication can be established.
 

Constructor Detail

RemoteFileNamePanel

public RemoteFileNamePanel(java.util.Map fileExtensions,
                           javax.swing.JComponent parent)
Constructor that allows setting of the file type extensions and the parent of this component.

Parameters:
fileExtensions - a Map containing the file type extensions in the form of (display text, file type) e.g. ("SAS Files", ".sas")
parent - the parent component of this panel
Method Detail

addActionButtons

public void addActionButtons(javax.swing.JButton action,
                             javax.swing.JButton cancel)
Allows setting of the action buttons.

Parameters:
action - the main action like Open, Save, OK
cancel - the cancel button

setRemoteFileViewComponent

public void setRemoteFileViewComponent(RemoteFileComponentInterface component)
Sets the view component (i.e. table view) so that listener communication can be established.

Parameters:
component - the view component that will provide events for the RemoteFileNamePanel

getFileName

public java.lang.String getFileName()
Returns the item(s) that are currently displayed in the file name field.

Returns:
the items in the file name field

propertyChange

public void propertyChange(java.beans.PropertyChangeEvent e)
Listens for changes in the selections made on the table component.

Specified by:
propertyChange in interface java.beans.PropertyChangeListener
Parameters:
e - the property change event



Copyright © 2009 SAS Institute Inc. All Rights Reserved.