spin.demo.complex
Class FileService

java.lang.Object
  extended by spin.demo.complex.FileService
All Implemented Interfaces:
DirectoryService

public class FileService
extends java.lang.Object
implements DirectoryService

Implementation of a file service.


Constructor Summary
FileService()
          Constructor.
FileService(java.io.File root)
          Constructor.
FileService(java.io.File root, java.io.FileFilter filter)
          Constructor.
FileService(java.lang.String root)
          Constructor.
 
Method Summary
 Directory[] getChildren(Directory directory)
          Get the children of a directory.
 Directory getRoot()
          Get the root directory.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FileService

public FileService()
Constructor.


FileService

public FileService(java.lang.String root)
Constructor.

Parameters:
root - root of this file service

FileService

public FileService(java.io.File root)
Constructor.

Parameters:
root - root of this file service

FileService

public FileService(java.io.File root,
                   java.io.FileFilter filter)
Constructor.

Parameters:
root - root of this file service
filter - filter of this file service
Method Detail

getRoot

public Directory getRoot()
Get the root directory.

Specified by:
getRoot in interface DirectoryService
Returns:
the root directory

getChildren

public Directory[] getChildren(Directory directory)
                        throws DirectoryServiceException
Get the children of a directory.

Specified by:
getChildren in interface DirectoryService
Parameters:
directory - directory to get children for
Returns:
children
Throws:
DirectoryServiceException


Copyright © 2007. All Rights Reserved.