|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.awt.Component
java.awt.Container
java.awt.Window
java.awt.Dialog
wt.clients.gui.WTFolderBrowserDialog
Nested Class Summary | |
(package private) class |
WTFolderBrowserDialog.DelayThread
|
(package private) class |
WTFolderBrowserDialog.SymAction
|
(package private) class |
WTFolderBrowserDialog.SymItem
|
(package private) class |
WTFolderBrowserDialog.SymJCAction
|
(package private) class |
WTFolderBrowserDialog.SymKey
|
(package private) class |
WTFolderBrowserDialog.SymMouse
|
(package private) class |
WTFolderBrowserDialog.SymWindow
|
Nested classes inherited from class java.awt.Dialog |
Dialog.AccessibleAWTDialog |
Nested classes inherited from class java.awt.Window |
Window.AccessibleAWTWindow |
Nested classes inherited from class java.awt.Container |
Container.AccessibleAWTContainer |
Nested classes inherited from class java.awt.Component |
Component.AccessibleAWTComponent, Component.BltBufferStrategy, Component.FlipBufferStrategy |
Field Summary | |
(package private) Label |
actionLabel
|
protected Vector |
allowedClasses
Vector of Classes to be shown in this browser dialog |
(package private) Panel |
buttonPanel
|
private static String |
CABINET_ROOT
Used as the first entry in the cabinet combobox to allow the user to select the root cabinet. |
(package private) Choice |
cabinetComboBox
|
protected Cabinet[] |
cabinets
Cabinets which can be browsed |
(package private) Button |
cancelButton
|
(package private) WTMultiListTable |
chooserTable
|
protected ThreadGroup |
contextGroup
ThreadGroup used in getting and setting the appropriate
WTContext . |
protected Folder |
currentFolder
Folder whose contents are currently displayed |
protected CabinetBased |
currentlySelectedItem
Variable used to track the currently selected CabinetBased item |
protected WTFolderBrowserDialog.DelayThread |
delayThread
Thread used to track double mouse clicks |
protected Vector |
disallowedClasses
Vector of Classes to be excluded from being displayed in
this browser dialog |
(package private) boolean |
fComponentsAdjusted
|
(package private) long |
firstClickTime
|
protected com.objectspace.jgl.HashMap |
folderEntries
HashMap which maintains the contents of a folder. |
protected CabinetBased |
folderEntry
Maintains the currently selected folder entry |
(package private) Label |
folderLocationLabel
|
protected boolean |
foldersOnly
Flag indicating whether or not this dialog should display only cabinets and folders. |
protected IconCache |
iconCache
Cache of images to be displayed in this browser table |
protected boolean |
initializeCabinets
Flag indicating whether or not this dialog should initialize the list of cabinets to be browsed |
protected Vector |
listeners
Vector of listeners who are notified when an object is
selected or when this dialog is cancelled. |
protected static int |
maximumRows
Maximum number of folder entries to display per column in this dialog |
(package private) Label |
nameLabel
|
(package private) TextField |
nameTextField
|
(package private) Button |
okButton
|
private Applet |
parentApplet
Deprecated. this variable is no longer used nor necessary |
protected String |
permission
String permission used in restricting which contents of a folder are displayed |
private static String |
RESOURCES
String which specifies the absolute class name of the
ResourceBundle corresponding to this dialog |
private static String |
RETRIEVED
Used to form a key for the hashmap whose corresponding value is the time at which a particular object was retrieved. |
protected Folder |
startingFolder
Folder whose contents are to be displayed when
the dialog is initially displayed. |
(package private) TextField |
statusTextField
|
private static String |
UP_IMAGE
Gif image file used for the up-arrow button. |
(package private) jclass.bwt.JCButton |
upButton
|
private static boolean |
VERBOSE
|
Fields inherited from class java.awt.Dialog |
|
Fields inherited from class java.awt.Window |
|
Fields inherited from class java.awt.Container |
|
Fields inherited from class java.awt.Component |
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
Fields inherited from interface java.awt.image.ImageObserver |
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
WTFolderBrowserDialog(Component parent,
boolean modal)
Constructor which uses a component as the parent of the dialog. |
|
WTFolderBrowserDialog(Component parent,
String title,
boolean modal)
Class constructor |
|
WTFolderBrowserDialog(Frame parent)
|
|
WTFolderBrowserDialog(Frame parent,
boolean modal)
|
|
WTFolderBrowserDialog(Frame parent,
String title,
boolean modal)
|
Method Summary | |
void |
addAllowedClass(Class allowed_class)
Method addAllowedClass is used to control which
type (Class ) of object can be displayed in the
table of this dialog. |
void |
addDisallowedClass(Class disallowed_class)
Method addDisallowedClass is used to control which
type (Class ) of object can be displayed in the
table of this dialog. |
private void |
addFolderEntry(int row,
int col,
FolderEntry object)
Method addFolderEntry adds the given FolderEntry
to the table of folder contents displayed by this dialog. |
void |
addListener(WTFolderBrowserListener a_listener)
Method addListener adds the given
WTFolderBrowserListener to receive notification when this
dialog is closed. |
void |
addNotify()
|
private void |
addSubFolder(int row,
int col,
Folder folder)
Method addSubFolder adds the given Folder
to the table of folder contents displayed by this dialog. |
(package private) void |
cabinetComboBox_ItemStateChanged(ItemEvent event)
|
(package private) void |
cancelButton_ActionPerformed(ActionEvent event)
|
(package private) void |
cancelButton_KeyPressed(KeyEvent event)
|
(package private) void |
chooserTable_mouseClicked(MouseEvent event)
|
private boolean |
contains(Object item,
Vector container)
Method contains determines whether or not the
given Vector contains the class corresponding
to the given Object . |
private void |
displayCabinets()
Display the cabinets as the contents of the table. |
private void |
enableActions(boolean enable)
Method enableActions controls whether or not
actions are available in this dialog. |
private Cabinet |
findCabinet(String cabinet_name)
Retrieves the Cabinet object from the array of
cabinets based upon the given cabinet name. |
private void |
getCabinetContents()
Method getCabinetContents is ultimately invoked as a
result of the user selecting a Cabinet from the
combobox of cabinet names. |
Cabinet[] |
getCabinets()
Returns the array of Cabinets which can be browsed and
selected in this dialog. |
private static Frame |
getComponentFrame(Component component)
|
private WTContext |
getContext()
Retrieves the WTContext associated with this dialog. |
CabinetBased |
getFolderEntry()
Method getFolderEntry returns the CabinetBased
object selected in this dialog. |
String |
getFolderPermission()
Method getFolderPermission returns the permission which
is used in filtering the folder contents which are retrieved. |
private static Frame |
getFrame(Component component)
Traverse the parent hierarchy of the given Component until a frame is found. |
protected String |
getLocalizedLabel(String key,
Object[] params)
Convenience method for returing a string message retrieved from the resource bundle associated with this class. |
private String |
getObjectKey(CabinetBased the_object)
Method getObjectKey returns a key value to be
used as the key associated with the given object in the hashmap
of folder contents. |
Applet |
getParentApplet()
Deprecated. the Applet is no longer used for context |
private Image |
getStandardIcon(Object object)
Method getStandardIcon attempts to retrieve the
Image which is associated with the given Object . |
private SortedEnumeration |
getSubFolders(Folder folder)
|
private boolean |
hasPermission()
Returns a boolean value which indicates whether or not a permission has been set on this dialog to use to control which cabinets, folders and objects to display. |
private void |
initCabinetCombobox()
Method to initialize the combobox of Cabinet choices
with the names of the cabinets. |
private void |
initCabinetRoot()
Initialize the String which represents the root of all cabinets. |
private void |
initializeCabinets()
Method to retrieve the initial list of Cabinets to be
displayed by this browser. |
private void |
initializeIconCache()
Method to initialize the cache of icons displayed in this dialog. |
private void |
initImages()
Method to initialize the image displayed on the up-arrow button. |
private boolean |
isChoosable(Object entry)
Method isChoosable determines whether a given object
can be chosen and consequently displayed in the table of folder
contents of this dialog. |
boolean |
isFoldersOnly()
|
boolean |
isInitializeCabinets()
Returns a boolean value which indicates whether or not this
dialog is set to initialize the list of Cabinets to be
displayed. |
private void |
localize()
Method to translate the field labels and button labels of this dialog according to the Locale of the client. |
private void |
notifyBrowserListeners(WTFolderBrowserEvent an_event)
Method to notify all WTFolderBrowserListeners when a
WTFolderBrowserEvent has been generated. |
(package private) void |
okButton_ActionPerformed(ActionEvent event)
|
(package private) void |
okButton_KeyPressed(KeyEvent event)
|
private void |
processCabinetSelect()
|
protected void |
processCancelCommand()
Method which handles the cancelling, or closing, of this dialog. |
protected void |
processOkCommand()
Method which handles the closing of this dialog. |
protected void |
processTableSelect(MouseEvent event)
|
private void |
processUpCommand()
|
void |
removeListener(WTFolderBrowserListener a_listener)
Method removeListener removes the given
WTFolderBrowserListener from the list of listeners to
WTFolderBrowserEvent events. |
private Cabinet[] |
retrieveCabinets()
Retrieves the cabinets that will be displayed in the cabinet drop-down. |
void |
setCabinets(Cabinet[] cabinets)
Method setCabinets sets the list of Cabinets
which can be browsed in this dialog. |
private void |
setContext(boolean context_on)
Sets the WTContext according to the given boolean value. |
private void |
setCurrentFolder(Folder folder)
|
protected void |
setDisplayLocation()
Attempt to set the location of this dialog to some intelligent position. |
private void |
setFolderEntry(CabinetBased cabinet_based)
|
void |
setFolderPermission(String permission)
Method setFolderPermission sets a permission which
is used in filtering the folder contents which are retrieved. |
void |
setFoldersOnly(boolean folders_only)
|
void |
setInitializeCabinets(boolean initialize_cabinets)
Method setInitializeCabinets is used to indicate whether
or not this dialog should initialize the list of Cabinets
to be displayed. |
void |
setInitializeCabinets(boolean initialize_cabinets,
String permission)
Method setInitializeCabinets is used to indicate whether
or not this dialog should initialize the list of Cabinets
to be displayed. |
void |
setParentApplet(Applet parent_applet)
Deprecated. the Applet is no longer used for context |
void |
setSelectionLabel(String label)
Sets the label which is associated with the currently selected value. |
void |
setStartingFolder(Folder folder)
Initializes this dialog to be opened to the given Folder. |
void |
setStartingFolder(String folder_path)
Initializes this dialog to be opened to the Folder associated with the given folder path. |
private void |
setStatus(String status)
Method setStatus is a convenience method used to set the
text of the status bar. |
void |
setVisible(boolean b)
Shows or hides the component depending on the boolean flag b. |
private void |
showMessageDialog(String message,
boolean modal)
Display a message dialog with the given string message. |
private Vector |
sortFolderEntries(Enumeration entries)
Method sortFolderEntries sorts the given enumeration
of CabinetBased objects. |
(package private) void |
upButton_actionPerformed(jclass.bwt.JCActionEvent event)
|
private void |
updateFoldersOnlyFlag()
Updates the flag indicating whether or not this dialog displays only folders. |
private void |
updateTable()
Method updateTable updates the table of Folder
contents when a new Folder is chosen as the current
Folder . |
(package private) void |
WTFolderBrowserDialog_WindowClosing(WindowEvent event)
|
Methods inherited from class java.awt.Dialog |
dispose, getAccessibleContext, getTitle, hide, isModal, isResizable, isUndecorated, paramString, setModal, setResizable, setTitle, setUndecorated, show |
Methods inherited from class java.lang.Object |
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
boolean fComponentsAdjusted
Label actionLabel
Choice cabinetComboBox
jclass.bwt.JCButton upButton
Label folderLocationLabel
WTMultiListTable chooserTable
Label nameLabel
TextField nameTextField
Panel buttonPanel
Button okButton
Button cancelButton
TextField statusTextField
private Applet parentApplet
protected ThreadGroup contextGroup
ThreadGroup
used in getting and setting the appropriate
WTContext
. This ThreadGroup replaces the use of a
parent applet.
protected WTFolderBrowserDialog.DelayThread delayThread
protected CabinetBased currentlySelectedItem
protected Vector allowedClasses
Classes
to be shown in this browser dialog
protected Folder currentFolder
Folder
whose contents are currently displayed
protected Cabinet[] cabinets
Cabinets
which can be browsed
protected Folder startingFolder
Folder
whose contents are to be displayed when
the dialog is initially displayed.
protected IconCache iconCache
protected Vector listeners
Vector
of listeners who are notified when an object is
selected or when this dialog is cancelled.
protected boolean initializeCabinets
protected CabinetBased folderEntry
protected Vector disallowedClasses
Classes
to be excluded from being displayed in
this browser dialog
protected com.objectspace.jgl.HashMap folderEntries
protected boolean foldersOnly
protected String permission
protected static int maximumRows
private static String UP_IMAGE
private static String RETRIEVED
private static String CABINET_ROOT
private static String RESOURCES
String
which specifies the absolute class name of the
ResourceBundle
corresponding to this dialog
private static boolean VERBOSE
long firstClickTime
Constructor Detail |
public WTFolderBrowserDialog(Frame parent)
public WTFolderBrowserDialog(Frame parent, boolean modal)
public WTFolderBrowserDialog(Frame parent, String title, boolean modal)
public WTFolderBrowserDialog(Component parent, boolean modal)
parent
- the parent Component of this dialogmodal
- a boolean
value indicating whether or not
this dialog should be modal.public WTFolderBrowserDialog(Component parent, String title, boolean modal)
parent
- the component for which the parent frame is foundtitle
- the String
title of this dialogmodal
- a boolean
value indicating whether or not
this dialog should be modal.Method Detail |
public void addNotify()
public void setVisible(boolean b)
b
- if true, show the component; otherwise, hide the component.Component.isVisible()
protected void setDisplayLocation()
private static Frame getFrame(Component component)
component
- the Component for which an associated
Frame is to be returned
private static Frame getComponentFrame(Component component)
private void initImages()
MediaTracker
to wait until the
image has completed loading.
MediaTracker
private void localize()
Locale
of the client.
#initResources
void WTFolderBrowserDialog_WindowClosing(WindowEvent event)
private WTContext getContext()
WTContext
associated with this dialog.
This method uses the ThreadGroup captured when this dialog was
constructed to retrieve the WTContext. If no WTContext is found
using the ThreadGroup, this method creates a new WTContext.
WTContext
associate with this dialogWTContext
private void setContext(boolean context_on)
context_on
- if true, the WTContext is set using the ThreadGroup
captured in the constructor of this dialog; otherwise, the
WTContext is set to null.getContext()
,
WTContext
public void setParentApplet(Applet parent_applet)
public Applet getParentApplet()
public void setSelectionLabel(String label)
label
- the String label to use as the label associated with
the currently selected value.private void initializeCabinets()
Cabinets
to be
displayed by this browser. This method retrieves, but does not
display the cabinets.
Cabinet
private void showMessageDialog(String message, boolean modal)
message
- the String message to displaymodal
- a boolean indicating whether or not the
dialog should be displayed as modalprivate void setStatus(String status)
setStatus
is a convenience method used to set the
text of the status bar.
status
- the String
value to display in the
status bar.private void enableActions(boolean enable)
enableActions
controls whether or not
actions are available in this dialog.
enable
- if true
, actions are enabled;
if false
, actions are disabled.protected String getLocalizedLabel(String key, Object[] params)
key
- the String resource bundle keyparams
- and parameters to be used in formatting the string
private Cabinet[] retrieveCabinets() throws WTException
WTException
private boolean hasPermission()
public void setCabinets(Cabinet[] cabinets)
setCabinets
sets the list of Cabinets
which can be browsed in this dialog. This method initializes the
combobox of Cabinet
names with the given list of
Cabinets
.
cabinets
- the array of Cabinet
items to be
displayed and browsed in this dialog.getCabinets()
public Cabinet[] getCabinets()
Cabinets
which can be browsed and
selected in this dialog.
setCabinets(wt.folder.Cabinet[])
public CabinetBased getFolderEntry()
getFolderEntry
returns the CabinetBased
object selected in this dialog.
CabinetBased
private void initCabinetCombobox()
Cabinet
choices
with the names of the cabinets. The names of the cabinets are
sorted alphabetically before being added to the combobox.
Cabinet
,
Sorting
private void initCabinetRoot()
private void initializeIconCache()
IconCache
must be initialized
before being used.
IconCache
private Cabinet findCabinet(String cabinet_name)
Cabinet
object from the array of
cabinets based upon the given cabinet name.
cabinet_name
- the String
name of the
cabinet to retrieve
Cabinet
with the given name, or
null
if no cabinet matching the given
name if found.private Vector sortFolderEntries(Enumeration entries)
sortFolderEntries
sorts the given enumeration
of CabinetBased
objects. The objects are sorted
based upon their type (i.e. Folder
, Part
)
and returned as a vector of CabinetBased
objects.
All objects of type Folder
are separated out and placed
first in the sorting order.
entries
- an Enumeration containing objects of type
FolderEntry
to be sorted.
CabinetBased
objects in which
the objects are in sorted order based upon their type.Enumeration
,
CabinetBased
private void displayCabinets()
private void addSubFolder(int row, int col, Folder folder)
addSubFolder
adds the given Folder
to the table of folder contents displayed by this dialog.
row
- specifies the row in which to place the given object in
the tablecol
- specifies the column in which to place the given object
in the tablefolder
- the Folder
object to be displayed in the
tableprivate Image getStandardIcon(Object object)
getStandardIcon
attempts to retrieve the
Image
which is associated with the given Object
.
This method utilizes the IconCache
to retrieve the
Image
.
object
- the Object
for which an Image
is to be retrieved
Image
which corresponds to the given
Object
IconCache
private void addFolderEntry(int row, int col, FolderEntry object)
addFolderEntry
adds the given FolderEntry
to the table of folder contents displayed by this dialog.
row
- specifies the row in which to place the given object in
the tablecol
- specifies the column in which to place the given object
in the tableobject
- the FolderEntry
object to be displayed in the
tableprivate boolean isChoosable(Object entry)
isChoosable
determines whether a given object
can be chosen and consequently displayed in the table of folder
contents of this dialog. If the particular class of the given
object is an element in the disallowedClasses
, then
the given object is not choosable. Otherwise, if the list of
allowedClasses
is not null, but does not contain
the class of the given object, then the object is not choosable.
If both the list of allowedClasses
and
disAllowed
classes are empty, then the given object
is considered to be choosable.
entry
- the Object
whose ability to be chosen
in the table of this dialog is determined
true
if the object can be chosen;
false
otherwiseaddAllowedClass(java.lang.Class)
,
addDisallowedClass(java.lang.Class)
private boolean contains(Object item, Vector container)
contains
determines whether or not the
given Vector
contains the class corresponding
to the given Object
. If the given object is an
instance of any of the classes in the given vector, the object
is considered to be contained in the given Vector, and true
is returned. This method is used by isChoosable to determine
whether or not a particular object is available to be selected.
item
- the Object
whose class is
searched for in the given Vector
container
- the Vector
of classes to be searched
for the class of the given Object
.
true
if the given object is an instance of a
of the classes contained in the given Vector;
false
otherwiseprivate String getObjectKey(CabinetBased the_object)
getObjectKey
returns a key value to be
used as the key associated with the given object in the hashmap
of folder contents.
the_object
- the CabinetBased
object whose
key value is returned.
String
key value corresponding to the
given object.public void addAllowedClass(Class allowed_class)
addAllowedClass
is used to control which
type (Class
) of object can be displayed in the
table of this dialog. If the list of allowed classes is not
null, then an object is only displayed in the table of
folder contents if that object has a class type that is
contained in the list of allowed classes.
Note that the list of allowed classes and the list of disallowed classes are mutually exclusive. That is, if the list of disallowed classes is non-empty, a particular folder entry will always be displayed in the table as long as its class type is not in the list of disallowed classes, regardless of the entries in the list of allowed classes. If the list of disallowed classes is empty, and the list of allowed classes is non-empty, then an object will only be displayed if its class type is found in the list of allowed classes. If both the list of allowed classes and the list of disallowed classes are empty, then a particular folder entry will always be displayed.
allowed_class
- the Class
to be added to the
list of classes which can be displayed in
the table of folder contents.addDisallowedClass(java.lang.Class)
public void addDisallowedClass(Class disallowed_class)
addDisallowedClass
is used to control which
type (Class
) of object can be displayed in the
table of this dialog. If the list of disallowed classes is not
null, then an object is only displayed in the table of
folder contents if that object has a class type that is not
contained in the list of disallowed classes.
Note that the list of allowed classes and the list of disallowed classes are mutually exclusive. That is, if the list of disallowed classes is non-empty, a particular folder entry will always be displayed in the table as long as its class type is not in the list of disallowed classes, regardless of the entries in the list of allowed classes. If the list of disallowed classes is empty, and the list of allowed classes is non-empty, then an object will only be displayed if its class type is found in the list of allowed classes. If both the list of allowed classes and the list of disallowed classes are empty, then a particular folder entry will always be displayed.
disallowed_class
- the Class
to be added to the
list of classes which cannot be displayed in
the table of folder contents.addAllowedClass(java.lang.Class)
public void setFolderPermission(String permission)
setFolderPermission
sets a permission which
is used in filtering the folder contents which are retrieved. If
a permission is given, when the contents of a folder are retrieved,
only those folder contents for which the user has this permission
are retrieved. For example:
WTFolderBrowserDialog browser = new WTFolderBrowserDialog( some_frame, true ); browser.setFolderPermission( WTPermission.MODIFY ); browser.setInitializeCabinets( true ); browser.show();will only display those folder contents for which the current user has modify permissions.
permission
- the String
permission which
specifies the permission which the current
user must have in order to be able to see
a particular object.WTPermission
,
getFolderPermission()
public String getFolderPermission()
getFolderPermission
returns the permission which
is used in filtering the folder contents which are retrieved. If
a permission is given, when the contents of a folder are retrieved,
only those folder contents for which the user has this permission
are retrieved. For example:
WTFolderBrowserDialog browser = new WTFolderBrowserDialog( some_frame, true ); browser.setFolderPermission( WTPermission.MODIFY ); browser.setInitializeCabinets( true ); browser.show();will only display those folder contents for which the current user has modify permissions.
String
permission which specifies the
permission which the current user must have in order to be
able to see a particular object.WTPermission
,
setFolderPermission(java.lang.String)
protected void processCancelCommand()
WTFolderBrowserListeners
that this dialog is being closed,
and then closes this dialog.
protected void processOkCommand()
WTFolderBrowserListeners
that
this dialog is being closed and then closes this dialog.
public void setInitializeCabinets(boolean initialize_cabinets)
setInitializeCabinets
is used to indicate whether
or not this dialog should initialize the list of Cabinets
to be displayed. If the given boolean
value is
true
, this dialog will retrieve the list of
Cabinets
from the database, and will initialize the
combobox of cabinet names. If the given value is false
,
the list of Cabinets
will not be initialized and must be
explicitly set via setCabinets
.
initialize_cabinets
- if true
, this dialog
will initialize the list of Cabinets
to be displayedsetInitializeCabinets(boolean,String)
public void setInitializeCabinets(boolean initialize_cabinets, String permission)
setInitializeCabinets
is used to indicate whether
or not this dialog should initialize the list of Cabinets
to be displayed. If the given boolean
value is
true
, this dialog will retrieve the list of
Cabinets
from the database, and will initialize the
combobox of cabinet names. If the given value is false
,
the list of Cabinets
will not be initialized and must be
explicitly set via setCabinets
.
The String
permission is used to filter the Cabinets
and Folders
which will be displayed to the user. When
the contents of a Cabinet
or Folder
is retrieved,
only those contents for which the user has the given permission will be
displayed. For example, a frame to create a new document may include a
means for invoking a WTFolderBrowserDialog
to allow the user
to pick the location in which to create the document. However, the dialog
should only display those cabinets and folders for which the user has
permission to modify, since creating a document in a particular folder may
require having modify permissions on that folder.
Eg:
WTFolderBrowserDialog browser = new WTFolderBrowserDialog( my_frame, true ); browser.setInitializeCabinets( true, WTPermission.MODIFY ); browser.show();
initialize_cabinets
- if true
, this dialog
will initialize the list of Cabinets
to be displayedpermission
- the String
permission. When
the contents of a selected Cabinet
or
Folder
are retrieved, only those contents for which
the current user has this permission will be retrieved.#setInitializeCabinets()
,
WTPermission
public boolean isInitializeCabinets()
boolean
value which indicates whether or not this
dialog is set to initialize the list of Cabinets
to be
displayed.
true
, this dialog will initialize the list of
Cabinets
private void updateFoldersOnlyFlag()
public boolean isFoldersOnly()
public void setFoldersOnly(boolean folders_only)
private void processCabinetSelect()
private void setFolderEntry(CabinetBased cabinet_based)
public void setStartingFolder(Folder folder) throws WTException
folder
- the starting folder of this dialog
WTException
- if an error occurs retrieving the contents
of the given folderpublic void setStartingFolder(String folder_path) throws FolderException, WTException
folder_path
- the String path corresponding to the starting
folder of this dialog
FolderException
- if an error occurs retrieving the contents
of the folder
WTException
- if an error occurs retrieving the contents
of the folderpublic void addListener(WTFolderBrowserListener a_listener)
addListener
adds the given
WTFolderBrowserListener
to receive notification when this
dialog is closed.
a_listener
- the WTFolderBrowserListener
interested
in receiving notification when this dialog closesremoveListener(wt.clients.gui.WTFolderBrowserListener)
,
WTFolderBrowserEvent
,
WTFolderBrowserListener
public void removeListener(WTFolderBrowserListener a_listener)
removeListener
removes the given
WTFolderBrowserListener
from the list of listeners to
WTFolderBrowserEvent
events. The given listener will
no longer receive notification when this dialog is closed. If the
given listener is not currently contained in the list, no action is
taken and the list is not modified.
a_listener
- the WTFolderBrowserListener
to be
removed from receiving notification when this
dialog closesaddListener(wt.clients.gui.WTFolderBrowserListener)
,
WTFolderBrowserEvent
,
WTFolderBrowserListener
private void notifyBrowserListeners(WTFolderBrowserEvent an_event)
WTFolderBrowserListeners
when a
WTFolderBrowserEvent
has been generated.
an_event
- the WTFolderBrowserEvent
which the
WTFolderBrowserListeners
will be
notified ofaddListener(wt.clients.gui.WTFolderBrowserListener)
,
removeListener(wt.clients.gui.WTFolderBrowserListener)
,
WTFolderBrowserEvent
,
WTFolderBrowserListener
private void updateTable() throws WTException
updateTable
updates the table of Folder
contents when a new Folder
is chosen as the current
Folder
. If the contents of the current folder have not
yet been retrieved and displayed, this method will retrieve the
folder contents. Otherwise, the folder contents will be retrieved
from the hashmap maintaining the folder contents. This method will
display a message in the status bar while the contents of the folder are
being retrieved and displayed.
WTException
- if an error occurs retrieving
the folders from the database.private SortedEnumeration getSubFolders(Folder folder) throws WTException
WTException
private void getCabinetContents()
getCabinetContents
is ultimately invoked as a
result of the user selecting a Cabinet
from the
combobox of cabinet names. This method sets the current folder
to be the cabinet currently selected in the combobox. The table
is updated to display the contents to the selected cabinet.
private void setCurrentFolder(Folder folder)
void cabinetComboBox_ItemStateChanged(ItemEvent event)
void upButton_actionPerformed(jclass.bwt.JCActionEvent event)
private void processUpCommand()
void chooserTable_mouseClicked(MouseEvent event)
protected void processTableSelect(MouseEvent event)
void okButton_ActionPerformed(ActionEvent event)
void okButton_KeyPressed(KeyEvent event)
void cancelButton_ActionPerformed(ActionEvent event)
void cancelButton_KeyPressed(KeyEvent event)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |