com.android.io
Interface IAbstractFolder

All Superinterfaces:
IAbstractResource
All Known Implementing Classes:
FolderWrapper

public interface IAbstractFolder
extends IAbstractResource

A folder.


Nested Class Summary
static interface IAbstractFolder.FilenameFilter
          Instances of classes that implement this interface are used to filter filenames.
 
Method Summary
 IAbstractFile getFile(java.lang.String name)
          Returns an IAbstractFile representing a child of the current folder with the given name.
 IAbstractFolder getFolder(java.lang.String name)
          Returns an IAbstractFolder representing a child of the current folder with the given name.
 boolean hasFile(java.lang.String name)
          Returns true if the receiver contains a file with a given name
 java.lang.String[] list(IAbstractFolder.FilenameFilter filter)
          Returns a list of all existing file and directory members in this folder that satisfy the specified filter.
 IAbstractResource[] listMembers()
          Returns a list of all existing file and directory members in this folder.
 
Methods inherited from interface com.android.io.IAbstractResource
delete, exists, getName, getOsLocation, getParentFolder
 

Method Detail

hasFile

boolean hasFile(java.lang.String name)
Returns true if the receiver contains a file with a given name

Parameters:
name - the name of the file. This is the name without the path leading to the parent folder.

getFile

IAbstractFile getFile(java.lang.String name)
Returns an IAbstractFile representing a child of the current folder with the given name. The file may not actually exist.

Parameters:
name - the name of the file.

getFolder

IAbstractFolder getFolder(java.lang.String name)
Returns an IAbstractFolder representing a child of the current folder with the given name. The folder may not actually exist.

Parameters:
name - the name of the folder.

listMembers

IAbstractResource[] listMembers()
Returns a list of all existing file and directory members in this folder. The returned array can be empty but is never null.


list

java.lang.String[] list(IAbstractFolder.FilenameFilter filter)
Returns a list of all existing file and directory members in this folder that satisfy the specified filter.

Parameters:
filter - A filename filter instance. Must not be null.
Returns:
An array of file names (generated using File.getName()). The array can be empty but is never null.