Remote Systems
v6.4.1

com.ibm.etools.systems.universal.miners
Class UniversalFileSystemFilter

java.lang.Object
  extended bycom.ibm.etools.systems.universal.miners.UniversalFileSystemFilter
All Implemented Interfaces:
FilenameFilter, IClientServerConstants, IUniversalDataStoreConstants

public class UniversalFileSystemFilter
extends Object
implements FilenameFilter, IUniversalDataStoreConstants, IClientServerConstants


Field Summary
protected  boolean allowDirs
           
protected  boolean allowFiles
           
protected  boolean caseSensitive
           
static String Copyright
           
protected  String filter
           
protected  NamePatternMatcher folderNameMatcher
           
protected  int includeFilesOrFolders
           
protected  IMatcher matcher
           
 
Fields inherited from interface com.ibm.etools.systems.universal.miners.IUniversalDataStoreConstants
BINARY_MODE, BUFFER_SIZE, C_DOWNLOAD_FILE, C_QUERY_QUALIFIED_CLASSNAME, C_QUERY_UNUSED_PORT, C_SYSTEM_ENCODING, DOWNLOAD_RESULT_EXCEPTION, DOWNLOAD_RESULT_FILE_NOT_FOUND_EXCEPTION, DOWNLOAD_RESULT_IO_EXCEPTION, DOWNLOAD_RESULT_SUCCESS_MESSAGE, DOWNLOAD_RESULT_SUCCESS_TYPE, DOWNLOAD_RESULT_UNEXPECTED_ERROR, DOWNLOAD_RESULT_UNSUPPORTED_ENCODING_EXCEPTION, FAILED, FAILED_TO_DELETE_DIR, FAILED_WITH_DOES_NOT_EXIST, FAILED_WITH_EXCEPTION, FAILED_WITH_EXIST, FAILED_WITH_SECURITY, KB_IN_BYTES, MESSAGE_DESCRIPTOR, NUM_OF_KB, SUCCESS, TEXT_MODE, TOKEN_SEPARATOR, TYPE_QUALIFIED_CLASSNAME, UNEXPECTED_ERROR, UNIVERSAL_ARCHIVE_FILE_DESCRIPTOR, UNIVERSAL_FILE_DESCRIPTOR, UNIVERSAL_FILESYSTEM_MINER, UNIVERSAL_FILTER_DESCRIPTOR, UNIVERSAL_FOLDER_DESCRIPTOR, UNIVERSAL_NODE_DESCRIPTOR, UNIVERSAL_TEMP_DESCRIPTOR, UNIVERSAL_VIRTUAL_FILE_DESCRIPTOR, UNIVERSAL_VIRTUAL_FOLDER_DESCRIPTOR, VERSION_1
 
Fields inherited from interface com.ibm.etools.systems.core.clientserver.IClientServerConstants
FILEMSG_ARCHIVE_CORRUPTED, FILEMSG_COPY_FILE_FAILED, FILEMSG_CREATE_FILE_FAILED, FILEMSG_CREATE_FILE_FAILED_EXIST, FILEMSG_CREATE_FOLDER_FAILED, FILEMSG_CREATE_FOLDER_FAILED_EXIST, FILEMSG_CREATE_RESOURCE_NOTVISIBLE, FILEMSG_DELETE_FILE_FAILED, FILEMSG_ERROR_NOFILETYPES, FILEMSG_MOVE_FILE_FAILED, FILEMSG_MOVE_TARGET_EQUALS_SOURCE, FILEMSG_NO_PERMISSION, FILEMSG_REMOTE_SAVE_FAILED, FILEMSG_RENAME_FILE_FAILED, FILEMSG_RENAME_RESOURCE_NOTVISIBLE, INCLUDE_ALL, INCLUDE_FILES_ONLY, INCLUDE_FOLDERS_ONLY, MSG_EXCEPTION_DELETING, MSG_EXCEPTION_MOVING, MSG_EXCEPTION_OCCURRED, MSG_EXCEPTION_RENAMING, MSG_PREFIX, PLUGIN_ID, PREFIX, RESID_PREFIX
 
Constructor Summary
UniversalFileSystemFilter(String fString, boolean files, boolean folders, boolean caseSensitive)
          Insert the method's description here.
 
Method Summary
 boolean accept(File dir, String nameFilter)
          Tests if a specified file should be included in a file list.
protected  void setListValues(int includeFilesOrFolders, String nameFilter)
           
protected  void setListValues(int includeFilesOrFolders, String folderNameFilter, String fileNameFilter)
          Overloaded method to set variables to affect the folder content subsetting, when there is separate filters for both folder names and filter names.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

Copyright

public static final String Copyright
See Also:
Constant Field Values

filter

protected String filter

allowDirs

protected boolean allowDirs

allowFiles

protected boolean allowFiles

caseSensitive

protected boolean caseSensitive

matcher

protected IMatcher matcher

folderNameMatcher

protected NamePatternMatcher folderNameMatcher

includeFilesOrFolders

protected int includeFilesOrFolders
Constructor Detail

UniversalFileSystemFilter

public UniversalFileSystemFilter(String fString,
                                 boolean files,
                                 boolean folders,
                                 boolean caseSensitive)
Insert the method's description here. Creation date: (2/22/01 1:15:54 PM)

Method Detail

accept

public boolean accept(File dir,
                      String nameFilter)
Tests if a specified file should be included in a file list.

Specified by:
accept in interface FilenameFilter
Parameters:
dir - the directory in which the file was found.
Returns:
true if and only if the name should be included in the file list; false otherwise.

setListValues

protected void setListValues(int includeFilesOrFolders,
                             String nameFilter)

setListValues

protected void setListValues(int includeFilesOrFolders,
                             String folderNameFilter,
                             String fileNameFilter)
Overloaded method to set variables to affect the folder content subsetting, when there is separate filters for both folder names and filter names.

Parameters:
includeFilesOrFolders - A constant from IFileConstants
folderNameFilter - The pattern to filter the folder names by. Can be null to include all folders

Remote Systems
v6.4.1

Copyright © 2005 IBM Corp. All Rights Reserved.

Note: This documentation is for part of an interim API that is still under development and expected to change significantly before reaching stability. It is being made available at this early stage to solicit feedback from pioneering adopters on the understanding that any code that uses this API will almost certainly be broken (repeatedly) as the API evolves.