This documentation differs from the official API. Jadeite adds extra features to the API including: variable font sizes, constructions examples, placeholders for classes and methods, and auto-generated “See Also” links. Additionally it is missing some items found in standard Javadoc documentation, including: generics type information, “Deprecated” tags and comments, “See Also” links, along with other minor differences. Please send any questions or feedback to bam@cs.cmu.edu.


javax.swing.plaf.basic
class BasicDirectoryModel

java.lang.Object extended by javax.swing.AbstractListModel extended by javax.swing.plaf.basic.BasicDirectoryModel
All Implemented Interfaces:
PropertyChangeListener, Serializable, ListModel

public class BasicDirectoryModel
extends AbstractListModel
implements PropertyChangeListener

Basic implementation of a file list.


Field Summary
 
Fields inherited from class javax.swing.AbstractListModel
listenerList
 
Constructor Summary

          
 
Method Summary
 void

          Adds a PropertyChangeListener to the listener list.
 boolean

          
 void

          
protected void
firePropertyChange(String propertyName, Object oldValue, Object newValue)

          Support for reporting bound property changes for boolean properties.
 Vector

          
 Object
getElementAt(int index)

          
 Vector

          
 PropertyChangeListener[]

          Returns an array of all the property change listeners registered on this component.
 int

          
 int

          
 void

          Obsolete - not used.
 void

          Obsolete - not used.
 void

          This method is used to interrupt file loading thread.
protected boolean
lt(File a, File b)

          
 void

          
 void

          Removes a PropertyChangeListener from the listener list.
 boolean
renameFile(File oldFile, File newFile)

          Renames a file in the underlying file system.
protected void

          
 void

          
 
Methods inherited from class javax.swing.AbstractListModel
addListDataListener, fireContentsChanged, fireIntervalAdded, fireIntervalRemoved, getListDataListeners, getListeners, removeListDataListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BasicDirectoryModel

public BasicDirectoryModel(JFileChooser filechooser)
Parameters:
filechooser
Method Detail

addPropertyChangeListener

public void addPropertyChangeListener(PropertyChangeListener listener)
Adds a PropertyChangeListener to the listener list. The listener is registered for all bound properties of this class.

If listener is null, no exception is thrown and no action is performed.

Parameters:
listener - the property change listener to be added

contains

public boolean contains(Object o)
Parameters:
o

fireContentsChanged

public void fireContentsChanged()

firePropertyChange

protected void firePropertyChange(String propertyName,
                                  Object oldValue,
                                  Object newValue)
Support for reporting bound property changes for boolean properties. This method can be called when a bound property has changed and it will send the appropriate PropertyChangeEvent to any registered PropertyChangeListeners.

Parameters:
propertyName - the property whose value has changed
oldValue - the property's previous value
newValue - the property's new value

getDirectories

public Vector getDirectories()

getElementAt

public Object getElementAt(int index)
Parameters:
index

getFiles

public Vector getFiles()

getPropertyChangeListeners

public PropertyChangeListener[] getPropertyChangeListeners()
Returns an array of all the property change listeners registered on this component.

Returns:
all of this component's PropertyChangeListeners or an empty array if no property change listeners are currently registered

getSize

public int getSize()

indexOf

public int indexOf(Object o)
Parameters:
o

intervalAdded

public void intervalAdded(ListDataEvent e)
Obsolete - not used.

Parameters:
e

intervalRemoved

public void intervalRemoved(ListDataEvent e)
Obsolete - not used.

Parameters:
e

invalidateFileCache

public void invalidateFileCache()
This method is used to interrupt file loading thread.


lt

protected boolean lt(File a,
                     File b)
Parameters:
a
b

propertyChange

public void propertyChange(PropertyChangeEvent e)
Parameters:
e

removePropertyChangeListener

public void removePropertyChangeListener(PropertyChangeListener listener)
Removes a PropertyChangeListener from the listener list.

If listener is null, no exception is thrown and no action is performed.

Parameters:
listener - the PropertyChangeListener to be removed

renameFile

public boolean renameFile(File oldFile,
                          File newFile)
Renames a file in the underlying file system.

Parameters:
oldFile - a File object representing the existing file
newFile - a File object representing the desired new file name
Returns:
true if rename succeeded, otherwise false

sort

protected void sort(Vector v)
Parameters:
v

validateFileCache

public void validateFileCache()


This documentation differs from the official API. Jadeite adds extra features to the API including: variable font sizes, constructions examples, placeholders for classes and methods, and auto-generated “See Also” links. Additionally it is missing some items found in standard Javadoc documentation, including: generics type information, “Deprecated” tags and comments, “See Also” links, along with other minor differences. Please send any questions or feedback to bam@cs.cmu.edu.
This page displays the Jadeite version of the documention, which is derived from the offical documentation that contains this copyright notice:
Copyright 2008 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms. Also see the documentation redistribution policy.
The official Sun™ documentation can be found here at http://java.sun.com/javase/6/docs/api/.