Local File Systems

In browsing a local file system, we have all the usual system calls for locating files and information about them.
c:\grd_source\kahuna\code\kahuna>dir *.java
 Volume in drive C has no label.
 Volume Serial Number is D8C1-9DC8

 Directory of c:\grd_source\kahuna\code\kahuna

02/27/03  04:53p                   931 AppEvent.java
02/27/03  04:53p                   652 AppEventListener.java
02/27/03  04:53p                   677 CandidateReleaseKey.java
02/27/03  04:53p                51,920 Main.java
02/27/03  04:53p                 4,951 Master.java
02/27/03  04:53p                 1,890 Version.java
               6 File(s)        108,968 bytes
                            326,308,864 bytes free
We make use of these methods in the LocalResourceServer.
public class LocalResourceServer extends ResourceServerBasics {

    public Resource[] getResources(Category category) {
        File[] files = getCatFile(category).listFiles(resourceFilter);
        if (files == null) {
            return new Resource[0];
        }
        Resource[] resources = new Resource[files.length];
        for (int i = 0; i < resources.length; i++) {
            resources[i] = new LocalResource(this, files[i]);
        }
        return resources;
    }
}