"Casteel, Don" wrote:
> 2.) Is there any way a Java application can obtain information on my hard
> drive, it's directory structure, directory size, and recursive information
> including file names and file sizes? I thought it would be cool to create a
> 3D map of my hard drive automatically in an application. The idea is the 3D
> map could work much the same as the FileDialog class
Yes, you can create a File object for, say, the root directory. Then
use the File's list() method to get the files in that directory.
Then you can go through each of the files and recursively get the
files in them if isDirectory() returns true.
If you make Swing DefautlMutableTreeNode's out of the files and
directories,
you can replicate the drive's file structure.
--
Tad Lamb
---------------------------------------------------
[EMAIL PROTECTED] | MAYA Viz Ltd.
Voice: 412.488.2900 | 2100 Wharton Street
Fax: 412.488.2940 | Pittsburgh, PA 15203
---------------------------------------------------
=====================================================================
To subscribe/unsubscribe, send mail to [EMAIL PROTECTED]
Java 3D Home Page: http://java.sun.com/products/java-media/3D/