Remote Systems
v6.4.1

com.ibm.etools.systems.universalfilesubsys.impl
Class UniversalFileSubSystemImpl

java.lang.Object
  extended byEObjectImpl
      extended bycom.ibm.etools.systems.subsystems.impl.SubSystemImpl
          extended bycom.ibm.etools.systems.subsystems.impl.RemoteFileSubSystemImpl
              extended bycom.ibm.etools.systems.universalfilesubsys.impl.UniversalFileSubSystemImpl
All Implemented Interfaces:
IAdaptable, ICommunicationsListener, IFileConstants, IRemoteObjectResolver, ISystemMessages, ISystemResourceChangeEvents, ISystemTypes, IUniversalDataStoreConstants, IUniversalSubSystem, RemoteFileSubSystem, SubSystem, SystemFilterPoolReferenceManagerProvider, UniversalFileSubSystem

public class UniversalFileSubSystemImpl
extends RemoteFileSubSystemImpl
implements IFileConstants, IUniversalDataStoreConstants, ISystemMessages, ISystemTypes, UniversalFileSubSystem, RemoteFileSubSystem, IUniversalSubSystem

See Also:
Serialized Form

Nested Class Summary
 
Nested classes inherited from class com.ibm.etools.systems.subsystems.impl.SubSystemImpl
SubSystemImpl.ConnectRunnable, SubSystemImpl.DisplayErrorMessageRunnable
 
Field Summary
protected  DataElement _downloadDescriptor
           
protected  int _fsMinerMajor
           
protected  int _fsMinerMinor
           
protected  int _fsMinerVersion
           
protected  DataElement _minerElement
           
protected  DataElement _queryAllDescriptor
           
protected  DataElement _queryFilesDescriptor
           
protected  DataElement _queryFoldersDescriptor
           
protected  DataElement _queryRemoteObjectDescriptor
           
protected  DataElement _uploadLogElement
           
static String copyright
           
protected  boolean showHidden
           
 
Fields inherited from class com.ibm.etools.systems.subsystems.impl.RemoteFileSubSystemImpl
_cachedRemoteFiles, _searchHistory, currFilterString, DEFAULT_CONTEXT, DEFAULT_CONTEXT_NOFILTERSTRING, FILTERSTRING_LISTROOTS, HOME_FOLDER_EDEFAULT, homeFolder, osCmdShell, osName, osVarsSet, osWindows, osWindows95, osWindowsNT
 
Fields inherited from class com.ibm.etools.systems.subsystems.impl.SubSystemImpl
_connectionError, _disconnecting, _system, ADDITIONAL_ATTRIBUTES_EDEFAULT, additionalAttributes, additionalAttributesESet, cancelable, DELIM_VENDOR_ATTR_VALUE, DELIM_VENDOR_ATTRS, DELIM_VENDOR_NAME, doConnection, FACTORY_ID_EDEFAULT, factoryId, filterPoolReferenceManager, hidden, HIDDEN_EDEFAULT, IBM_ATTRIBUTES_EDEFAULT, ibmAttributes, ibmAttributesESet, ibmAttrs, monitor, name, NAME_EDEFAULT, operation, OPERATION_CANCEL_SHELL, OPERATION_CONNECT, OPERATION_DISCONNECT, OPERATION_GET_PROPERTIES, OPERATION_GET_PROPERTY, OPERATION_REMOVE_SHELL, OPERATION_RESOLVE_ABSOLUTE, OPERATION_RESOLVE_ABSOLUTES, OPERATION_RESOLVE_RELATIVE, OPERATION_RUN_COMMAND, OPERATION_RUN_SHELL, OPERATION_SEND_COMMAND_TO_SHELL, OPERATION_SET_PROPERTIES, OPERATION_SET_PROPERTY, parentConnection, parentSubSystemFactory, pmDialog, port, PORT_EDEFAULT, previousUserIdKey, remoteServerLauncher, runContext, runException, runInput, runInput2, runInputs, runInputs2, runInterpret, runInThread, runObject, runOutput, runOutputs, runOutputString, runOutputStrings, saveFileName, shell, sortResults, SUBSYSTEM_FILE_NAME, supportsConnecting, USE_SSL_EDEFAULT, USER_ID_EDEFAULT, userId, useSSL, VENDOR_ATTRIBUTES_EDEFAULT, vendorAttributes, vendorAttributesESet, vendorAttrs
 
Fields inherited from interface com.ibm.etools.systems.subsystems.IFileConstants
LINE_SEPARATOR_BYTE_ARRAY_UNIX, LINE_SEPARATOR_BYTE_ARRAY_WINDOWS, PATH_SEPARATOR_CHAR_UNIX, PATH_SEPARATOR_CHAR_WINDOWS, PATH_SEPARATOR_UNIX, PATH_SEPARATOR_WINDOWS, SEPARATOR_CHAR_UNIX, SEPARATOR_CHAR_WINDOWS, SEPARATOR_UNIX, SEPARATOR_WINDOWS
 
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, Copyright, 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.ISystemMessages
FILEMSG_ARCHIVE_CORRUPTED, FILEMSG_COPY_FILE_FAILED, FILEMSG_COPY_ROOT, 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_DELETING, FILEMSG_DESTINATION_CONFLICTING, FILEMSG_DESTINATION_EMPTY, FILEMSG_ERROR_NOFILETYPES, FILEMSG_EXPORT_ERROR, FILEMSG_EXPORT_FAILED, FILEMSG_EXPORT_NONE_SELECTED, FILEMSG_EXPORT_PROBLEMS, FILEMSG_FILE_NOTFOUND, FILEMSG_FOLDER_IS_FILE, FILEMSG_FOLDER_NOTEMPTY, FILEMSG_FOLDER_NOTFOUND, FILEMSG_FOLDER_NOTFOUND_WANTTOCREATE, FILEMSG_IMPORT_ERROR, FILEMSG_IMPORT_FAILED, FILEMSG_IMPORT_FILTERING, FILEMSG_IMPORT_NONE_SELECTED, FILEMSG_IMPORT_PROBLEMS, FILEMSG_IMPORT_SELF, FILEMSG_IO_ERROR, FILEMSG_MOVE_FILE_FAILED, FILEMSG_MOVE_TARGET_DESCENDS_FROM_SOUCE, FILEMSG_MOVE_TARGET_EQUALS_SOURCE, FILEMSG_NOT_WRITABLE, FILEMSG_RENAME_FILE_FAILED, FILEMSG_RENAME_RESOURCE_NOTVISIBLE, FILEMSG_SECURITY_ERROR, FILEMSG_SOURCE_EMPTY, FILEMSG_SOURCE_IS_FILE, FILEMSG_TARGET_EXISTS, FILEMSG_VALIDATE_FILEFILTERSTRING_EMPTY, FILEMSG_VALIDATE_FILEFILTERSTRING_NOINCLUDES, FILEMSG_VALIDATE_FILEFILTERSTRING_NOTUNIQUE, FILEMSG_VALIDATE_FILEFILTERSTRING_NOTVALID, MSG_ADDTO_VIRTUAL_DEST, MSG_CACHE_UNABLE_TO_SYNCH, MSG_CACHE_UPLOAD_BEFORE_DELETE, MSG_COMBINETO_VIRTUAL_DEST, MSG_COMM_AUTH_FAILED, MSG_COMM_CLIENT_OLDER_WARNING, MSG_COMM_CONNECT_FAILED, MSG_COMM_DAEMON_NOTSTARTED, MSG_COMM_ENVVAR_DUPLICATE, MSG_COMM_ENVVAR_INVALIDCHAR, MSG_COMM_ENVVAR_NONAME, MSG_COMM_INCOMPATIBLE_PROTOCOL, MSG_COMM_INCOMPATIBLE_UPDATE, MSG_COMM_INVALID_LOGIN, MSG_COMM_PORT_WARNING, MSG_COMM_PWD_BLANKFIELD, MSG_COMM_PWD_EXISTS, MSG_COMM_PWD_INVALID, MSG_COMM_PWD_MISMATCH, MSG_COMM_REXEC_NOTSTARTED, MSG_COMM_SERVER_NOTSTARTED, MSG_COMM_SERVER_OLDER_WARNING, MSG_CONFIRM_CHANGES, MSG_CONFIRM_CHANGES_CANCELABLE, MSG_CONFIRM_DELETE, MSG_CONFIRM_DELETE_USERACTION, MSG_CONFIRM_DELETE_USERTYPE, MSG_CONFIRM_DELETEPROFILE, MSG_CONFIRM_DELETEREMOTE, MSG_CONFIRM_ENABLE_CLASSIC_HELP, MSG_CONFIRM_RELOADRSE, MSG_CONNECT_CANCELLED, MSG_CONNECT_DAEMON_FAILED, MSG_CONNECT_DAEMON_FAILED_EXCEPTION, MSG_CONNECT_FAILED, MSG_CONNECT_PROGRESS, MSG_CONNECT_SSL_EXCEPTION, MSG_CONNECT_UNKNOWNHOST, MSG_CONNECTING_TO_SERVER, MSG_CONNECTION_DELETED, MSG_CONNECTWITHPORT_PROGRESS, MSG_CONVERTTO_VIRTUAL_DEST, MSG_COPY_PROGRESS, MSG_COPYCONNECTION_PROGRESS, MSG_COPYCONNECTIONS_PROGRESS, MSG_COPYFILTER_PROGRESS, MSG_COPYFILTERPOOL_COMPLETE, MSG_COPYFILTERPOOL_PROGRESS, MSG_COPYFILTERPOOLS_PROGRESS, MSG_COPYFILTERS_PROGRESS, MSG_COPYFILTERSTRING_PROGRESS, MSG_COPYFILTERSTRINGS_PROGRESS, MSG_COPYGENERIC_PROGRESS, MSG_COPYSUBSYSTEMS_PROGRESS, MSG_COPYTHINGGENERIC_PROGRESS, MSG_DEST_NOT_IN_SOURCE, MSG_DEST_TARGET_READONLY, MSG_DISCONNECT_CANCELLED, MSG_DISCONNECT_FAILED, MSG_DISCONNECT_PROGRESS, MSG_DISCONNECTWITHPORT_PROGRESS, MSG_DOWNLOAD_ALREADY_OPEN_IN_EDITOR, MSG_DOWNLOAD_NO_WRITE, MSG_DOWNLOAD_PROGRESS, MSG_DOWNLOADING_PROGRESS, MSG_ERROR_CONNECTION_NOTFOUND, MSG_ERROR_ENABLE_CLASSIC_HELP, MSG_ERROR_EXTENSION_EMPTY, MSG_ERROR_FILE_NOTFOUND, MSG_ERROR_FILENAME_INVALID, MSG_ERROR_FOLDER_NOTFOUND, MSG_ERROR_FOLDERORFILE_NOTFOUND, MSG_ERROR_GENERAL, MSG_ERROR_LIST_TITLE, MSG_ERROR_PROFILE_NOTFOUND, MSG_ERROR_UNEXPECTED, MSG_EXCEPTION_DELETING, MSG_EXCEPTION_MOVING, MSG_EXCEPTION_OCCURRED, MSG_EXCEPTION_RENAMING, MSG_EXPAND_CANCELLED, MSG_EXPAND_CONNECTIONCREATED, MSG_EXPAND_EMPTY, MSG_EXPAND_FAILED, MSG_EXPAND_FILTERCREATED, MSG_EXPAND_PREFIX, MSG_EXTRACT_PROGRESS, MSG_FILE_INUSE, MSG_FILTERPOOL_CREATED, MSG_FOLDER_INUSE, MSG_GENERIC_E, MSG_GENERIC_E_HELP, MSG_GENERIC_E_TWOPARMS_HELP, MSG_GENERIC_I, MSG_GENERIC_I_HELP, MSG_GENERIC_I_TWOPARMS_HELP, MSG_GENERIC_Q, MSG_GENERIC_Q_HELP, MSG_GENERIC_Q_TWOPARMS_HELP, MSG_GENERIC_U, MSG_GENERIC_U_HELP, MSG_GENERIC_U_TWOPARMS_HELP, MSG_GENERIC_W, MSG_GENERIC_W_HELP, MSG_GENERIC_W_TWOPARMS_HELP, MSG_HOSTNAME_NOTFOUND, MSG_HOSTNAME_VERIFYING, MSG_IMPORT_EXPORT_UNABLE_TO_USE_CONNECTION, MSG_IMPORT_EXPORT_UNEXPECTED_EXCEPTION, MSG_INITIALIZING_SERVER, MSG_LIST_CANCELLED, MSG_LIST_PREFIX, MSG_LOADING_PROFILE_SHOULDBE_ACTIVATED, MSG_LOADING_PROFILE_SHOULDNOTBE_DEACTIVATED, MSG_MOVE_PROGRESS, MSG_MOVECONNECTION_PROGRESS, MSG_MOVECONNECTIONS_PROGRESS, MSG_MOVEFILTER_PROGRESS, MSG_MOVEFILTERPOOL_COMPLETE, MSG_MOVEFILTERPOOL_PROGRESS, MSG_MOVEFILTERPOOLS_PROGRESS, MSG_MOVEFILTERS_PROGRESS, MSG_MOVEFILTERSTRING_PROGRESS, MSG_MOVEFILTERSTRINGS_PROGRESS, MSG_MOVEGENERIC_PROGRESS, MSG_MOVETHINGGENERIC_PROGRESS, MSG_OFFLINE_CANT_CONNECT, MSG_OPERATION_CANCELLED, MSG_OPERATION_DISCONNECTED, MSG_OPERATION_FAILED, MSG_OPERATION_FINISHED, MSG_OPERATION_RUNNING, MSG_OPERTION_STOPPED, MSG_PERCENT_DONE, MSG_PREFIX, MSG_QUERY_PROGRESS, MSG_QUERY_PROPERTIES_PROGRESS, MSG_REMOTE_JAR_EXPORT_OVERWRITE_FILE, MSG_REMOTE_SEARCH_INVALID_REGEX, MSG_RENAMEFILTER_FAILED, MSG_RESOLVE_PROGRESS, MSG_RESTORE_FAILED, MSG_RUN_PROGRESS, MSG_SAVE_CHANGES_PENDING, MSG_SAVE_FAILED, MSG_SAVING_PROGRESS, MSG_SET_PROGRESS, MSG_SET_PROPERTIES_PROGRESS, MSG_STARTING_SERVER_VIA_DAEMON, MSG_STARTING_SERVER_VIA_REXEC, MSG_SYNCHRONIZE_PROGRESS, MSG_TRANSFER_INVALID, MSG_UCMD_INVOCATION_EMPTY, MSG_UDA_LOAD_ERROR, MSG_UDA_ROOTTAG_ERROR, MSG_UFF_PATTERN_EMPTY, MSG_UFF_PATTERN_INVALID_REGEX, MSG_UNDERCONSTRUCTION, MSG_UPDATEFILTER_FAILED, MSG_UPLOAD_FILE_EXISTS, MSG_UPLOAD_PROGRESS, MSG_UPLOADING_PROGRESS, MSG_VALIDATE_ARCHIVE_NAME, MSG_VALIDATE_COMPILELABEL_EMPTY, MSG_VALIDATE_COMPILELABEL_NOTUNIQUE, MSG_VALIDATE_COMPILELABEL_NOTVALID, MSG_VALIDATE_COMPILESTRING_EMPTY, MSG_VALIDATE_COMPILESTRING_NOTVALID, MSG_VALIDATE_CONNECTIONNAME_EMPTY, MSG_VALIDATE_CONNECTIONNAME_NOTUNIQUE, MSG_VALIDATE_CONNECTIONNAME_NOTUNIQUE_OTHERPROFILE, MSG_VALIDATE_CONNECTIONNAME_NOTVALID, MSG_VALIDATE_ENTRY_EMPTY, MSG_VALIDATE_ENTRY_NOTUNIQUE, MSG_VALIDATE_ENTRY_NOTVALID, MSG_VALIDATE_FILENAME_NOTVALID, MSG_VALIDATE_FILTERNAME_EMPTY, MSG_VALIDATE_FILTERNAME_NOTUNIQUE, MSG_VALIDATE_FILTERNAME_NOTVALID, MSG_VALIDATE_FILTERPOOLNAME_EMPTY, MSG_VALIDATE_FILTERPOOLNAME_NOTUNIQUE, MSG_VALIDATE_FILTERPOOLNAME_NOTVALID, MSG_VALIDATE_FILTERSTRING_ALREADYEXISTS, MSG_VALIDATE_FILTERSTRING_DUPLICATES, MSG_VALIDATE_FILTERSTRING_EMPTY, MSG_VALIDATE_FILTERSTRING_NOTUNIQUE, MSG_VALIDATE_FILTERSTRING_NOTVALID, MSG_VALIDATE_FOLDERNAME_NOTVALID, MSG_VALIDATE_HOSTNAME_EMPTY, MSG_VALIDATE_NAME_EMPTY, MSG_VALIDATE_NAME_NOTUNIQUE, MSG_VALIDATE_NAME_NOTVALID, MSG_VALIDATE_NOT_NUMERIC, MSG_VALIDATE_NUMBER_EMPTY, MSG_VALIDATE_NUMBER_NOTVALID, MSG_VALIDATE_NUMBER_OUTOFRANGE, MSG_VALIDATE_PASSWORD_EMPTY, MSG_VALIDATE_PASSWORD_EXPIRED, MSG_VALIDATE_PATH_EMPTY, MSG_VALIDATE_PATH_NOTUNIQUE, MSG_VALIDATE_PATH_NOTVALID, MSG_VALIDATE_PORT_EMPTY, MSG_VALIDATE_PORT_NOTVALID, MSG_VALIDATE_PROFILENAME_EMPTY, MSG_VALIDATE_PROFILENAME_NOTUNIQUE, MSG_VALIDATE_PROFILENAME_NOTVALID, MSG_VALIDATE_PROFILENAME_RESERVED, MSG_VALIDATE_RENAME_EMPTY, MSG_VALIDATE_RENAME_NOTUNIQUE, MSG_VALIDATE_RENAME_NOTVALID, MSG_VALIDATE_RENAME_OLDEQUALSNEW, MSG_VALIDATE_SRCTYPE_EMPTY, MSG_VALIDATE_SRCTYPE_NOTUNIQUE, MSG_VALIDATE_SRCTYPE_NOTVALID, MSG_VALIDATE_UDACMD_EMPTY, MSG_VALIDATE_UDACMD_NOTVALID, MSG_VALIDATE_UDACMT_EMPTY, MSG_VALIDATE_UDACMT_NOTVALID, MSG_VALIDATE_UDANAME_EMPTY, MSG_VALIDATE_UDANAME_NOTUNIQUE, MSG_VALIDATE_UDANAME_NOTVALID, MSG_VALIDATE_UDTNAME_EMPTY, MSG_VALIDATE_UDTNAME_NOTUNIQUE, MSG_VALIDATE_UDTNAME_NOTVALID, MSG_VALIDATE_UDTTYPES_EMPTY, MSG_VALIDATE_UDTTYPES_NOTVALID, MSG_VALIDATE_USERID_EMPTY, MSG_VALIDATE_USERID_NOTVALID, MSG_WIZARD_PAGE_ERROR, NEW_FILE_ACTION, NEW_FILE_WIZARD, NEW_FOLDER_ACTION, NEW_FOLDER_WIZARD, PLUGIN_ID, PREFIX, RESID_PREFIX
 
Fields inherited from interface com.ibm.etools.systems.core.ISystemTypes
SYSTEMTYPE_AIX, SYSTEMTYPE_ISERIES, SYSTEMTYPE_LINUX, SYSTEMTYPE_LOCAL, SYSTEMTYPE_PASE, SYSTEMTYPE_POWER_LINUX, SYSTEMTYPE_UNIX, SYSTEMTYPE_WINDOWS, SYSTEMTYPE_ZSERIES, SYSTEMTYPE_ZSERIES_LINUX
 
Fields inherited from interface com.ibm.etools.systems.subsystems.IRemoteObjectResolver
Copyright
 
Fields inherited from interface com.ibm.etools.systems.universal.IUniversalSubSystem
Copyright
 
Fields inherited from interface com.ibm.etools.systems.model.ISystemResourceChangeEvents
EVENT_ADD, EVENT_ADD_FILTER_REFERENCE, EVENT_ADD_FILTERSTRING_REFERENCE, EVENT_ADD_MANY, EVENT_ADD_RELATIVE, EVENT_CHANGE_CHILDREN, EVENT_CHANGE_FILTER_REFERENCE, EVENT_CHANGE_FILTERSTRING_REFERENCE, EVENT_COLLAPSE_ALL, EVENT_COLLAPSE_SELECTED, EVENT_COMMAND_FINISHED, EVENT_COMMAND_HISTORY_UPDATE, EVENT_COMMAND_MESSAGE, EVENT_COMMAND_RUN, EVENT_COMMAND_SHELL_FINISHED, EVENT_COMMAND_SHELL_REMOVED, EVENT_COMPILE_COMMAND_RUN, EVENT_DELETE, EVENT_DELETE_FILTER_REFERENCE, EVENT_DELETE_FILTERSTRING_REFERENCE, EVENT_DELETE_MANY, EVENT_EXPAND_SELECTED, EVENT_ICON_CHANGE, EVENT_MOVE_FILTER_REFERENCES, EVENT_MOVE_FILTERSTRING_REFERENCES, EVENT_MOVE_MANY, EVENT_MUST_COLLAPSE, EVENT_PROPERTY_CHANGE, EVENT_PROPERTYSHEET_UPDATE, EVENT_REFRESH, EVENT_REFRESH_REMOTE, EVENT_REFRESH_SELECTED, EVENT_REFRESH_SELECTED_FILTER, EVENT_REFRESH_SELECTED_PARENT, EVENT_RENAME, EVENT_RENAME_FILTER_REFERENCE, EVENT_REPLACE_CHILDREN, EVENT_REVEAL_AND_SELECT, EVENT_SEARCH_FINISHED, EVENT_SELECT, EVENT_SELECT_EXPAND, EVENT_SELECT_REMOTE, PROPERTYSHEET_UPDATE_EVENT
 
Constructor Summary
UniversalFileSubSystemImpl()
          Constructor.
 
Method Summary
 void cancelSearch(IRemoteSearchResultConfiguration searchConfig)
          Given a search configuration, cancel the search.
protected  void checkForNetworkErrors()
          Check if any network errors have occured.
protected  IRemoteFile[] convertObjsToRemoteFiles(IRemoteFileContext context, String folderFilter, String fileFilter, Object[] objs, boolean isRoot, boolean exists)
          Helper method to convert DataElement objects to IRemoteFile objects when we know if it exists or not, but not whether it is a directory or not.
protected  IRemoteFile[] convertObjsToRemoteFiles(IRemoteFileContext context, String folderFilter, String fileFilter, Object[] objs, boolean isRoot, boolean exists, boolean isDir)
          Helper method to convert DataElement objects to IRemoteFile objects when we know if it exists or not, and whether it is a directory or not.
protected  IRemoteFile convertObjToRemoteFile(IRemoteFileContext context, Object obj)
          Helper method to convert single DataElement object to IRemoteFile object
protected  IRemoteFile convertObjToRemoteFile(IRemoteFileContext context, Object obj, boolean exists)
          Helper method to convert single DataElement object to IRemoteFile object
 void copy(InputStream stream, long totalBytes, IRemoteFile destination, String encoding, IProgressMonitor monitor)
          Put local data to a remote location.
 boolean copy(IRemoteFile sourceFolderOrFile, IRemoteFile targetFolder, String newName, IProgressMonitor monitor)
          Copy a file or folder to a new target parent folder.
 void copy(IRemoteFile source, String destination, String encoding, IProgressMonitor monitor)
          Get the remote file and save it locally.
 void copy(String source, IRemoteFile destination, String encoding, IProgressMonitor monitor)
          Put the local copy of the remote file back to the remote location.
 void copyLocalToRemote(InputStream stream, long totalBytes, String srcEncoding, String remotePath, String rmtEncoding, IProgressMonitor monitor)
          Uploads local data to a remote file.
 void copyLocalToRemote(String source, String destination, IProgressMonitor monitor)
          Put the local copy of the remote file back to the remote location.
 void copyLocalToRemote(String source, String srcEncoding, String remotePath, String rmtEncoding, IProgressMonitor monitor)
          Put the local copy of the remote file back to the remote location.
 IRemoteFile createFile(IRemoteFile fileToCreate)
          Create a new file, given its IRemoteFile object (these do not have to represent existing files).
 IRemoteFile createFolder(IRemoteFile folderToCreate)
          Create a new folder, given its IRemoteFile object (these do not have to represent existing folders) The parent folder must exist for this to succeed.
 IRemoteFile createFolders(IRemoteFile folderToCreate)
          Given an IRemoteFile for a folder, this will create that folder and any missing parent folders in its path.
 boolean delete(IRemoteFile folderOrFile)
          Delete the given remote file or folder.
 Object eGet(EStructuralFeature eFeature, boolean resolve)
           
 NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, Class baseClass, NotificationChain msgs)
           
 NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, Class baseClass, NotificationChain msgs)
           
 boolean eIsSet(EStructuralFeature eFeature)
           
 void eSet(EStructuralFeature eFeature, Object newValue)
           
protected  EClass eStaticClass()
           
 void eUnset(EStructuralFeature eFeature)
           
protected  DataElement findUploadLog()
           
protected  DataElement findUploadStatusFor(String remotePath)
           
protected  DataStore getDataStore()
          Helper method to return the DataStore object needed by comm layer.
protected  String getDataStoreRoot()
           
 int getDownloadBufferSize()
           
protected  DataElement getDownloadDescriptor(DataElement remoteElement)
           
protected  DataElement getFileSystemMinerElement()
           
protected  int getFileSystemMinerVersion()
           
 ILanguageUtilityFactory getLanguageUtilityFactory()
          Returns an instance of UniversalLanguageUtilityFactory.
 InetAddress getLocalAddress()
          Gets an unused port on the remote host, connects to it and asks the socket for the local connection.
 IRemoteFile getParentFolder(IRemoteFile folderOrFile)
          Given a folder or file, return its parent folder object.
 String getQualifiedClassName(IRemoteFile classFile)
           
protected  DataElement getQueryAllDescriptor(DataElement remoteElement)
           
protected  DataElement getQueryFilesDescriptor(DataElement remoteElement)
           
protected  DataElement getQueryFoldersDescriptor(DataElement remoteElement)
           
protected  DataElement getQueryRemoteObjectDescriptor(DataElement remoteElement)
           
 String getRemoteEncoding()
          Get the encoding of the remote machine
 IRemoteFileFactory getRemoteFileFactory()
           
 IRemoteFile getRemoteFileObject(IRemoteFile parent, String folderOrFileName)
          Given a un-qualified file or folder name, and its parent folder object, return an IRemoteFile object for the file.
 IRemoteFile getRemoteFileObject(String folderOrFileName)
          Given a fully qualified file or folder name, return an IRemoteFile object for it.
 IRemoteSearchResultConfigurationFactory getRemoteSearchResultConfigurationFactory()
          Gets the search result configuration factory associated with the subsystem.
 AbstractSystemManager getSystemManager()
          Return a singleton instance of an AbstractSystemManager subclass that manages a pool of ISystem objects, one per system connection.
 UniversalCmdSubSystemImpl getUniversalCmdSubSystem()
          Retrieve the peer Universal command subsystem for for this connection
 int getUnusedPort()
          Returns an unused port number on the remote host that could be used by any tool on the host.
 int getUploadBufferSize()
           
protected  int[] getWellKnownRemotePorts()
          Gets an array of well known ports on the remote system.
 boolean isCaseSensitive()
          Return true if file names are case-sensitive.
protected  boolean isSpecialChar(char c)
          Checks whether the given character is a special character in the shell.
 IRemoteFile[] listFiles(IRemoteFile parent, String fileNameFilter, IRemoteFileContext context)
          Return a list of remote files in the given folder, which match the given name pattern.
 IRemoteFile[] listFolders(IRemoteFile parent, String folderNameFilter, IRemoteFileContext context)
          Return a subsetted list of remote folders in the given parent folder on the remote system.
 IRemoteFile[] listFoldersAndFiles(IRemoteFile parent, String fileNameFilter, IRemoteFileContext context)
          Return a list of remote folders and files in the given folder.
 IRemoteFile[] listRoots(IRemoteFileContext context)
          Return a list of roots/drives on the remote system
 void markCachedStale(String absolutePath)
           
 boolean move(IRemoteFile sourceFolderOrFile, IRemoteFile targetFolder, String newName)
          Move a file or folder to a new target parent folder.
protected  String prepareForDownload(String localPath)
           
 boolean rename(IRemoteFile folderOrFile, String newName)
          Rename the given remote file or folder.
 void search(IRemoteSearchResultConfiguration searchConfig)
          Given a search configuration, searches for its results.
protected  SubSystem selectCommandSubSystem(SubSystem[] allCmdSubSystems)
          Internal method to select the appropriate command subsystem when there are multiple defined for this connection.
 void setAttributes(DataElement deObj, String fileNameFilter, boolean showHidden)
          The attributes sent to the miner - required for the query.
protected  void setDataStoreRoot(String root)
           
 boolean setLastModified(IRemoteFile folderOrFile, long newDate)
          Set the last modified date for the given file or folder.
 boolean setReadOnly(IRemoteFile folderOrFile)
          Set this file to be readonly.
 ArrayList setSearchAttributes(String textString, boolean isCaseSensitive, boolean isTextRegex, String fileNamesString, boolean isFileNamesRegex, boolean includeArchives, boolean includeSubfolders, String classificationString, boolean showHidden)
           
protected  void showUploadFailedMessage(FileTransferStatusListener listener, String source)
           
 
Methods inherited from class com.ibm.etools.systems.subsystems.impl.RemoteFileSubSystemImpl
accept, addResolvedFilterStringObjects, cacheRemoteFile, cacheRemoteFile, checkForCancel, communicationsStateChange, copy, copy, copy, copy, copy, copy, copyUTF8, copyUTF8, copyUTF8, copyUTF8, doesFilterStringListContentsOf, doesFilterStringMatch, getCachedRemoteFile, getContext, getContext, getCurrentFilterString, getDefaultContext, getDefaultContextNoFilterString, getFilterStringListRoots, getFirstParentFilterString, getHomeFolder, getLineSeparator, getObjectWithAbsoluteName, getParentFolderName, getParentRemoteFileSubSystemFactory, getPathSeparator, getPathSeparatorChar, getPropertyPage, getRemoteSearchResultObject, getSeparator, getSeparatorChar, getTargetForFilter, internalResolveFilterString, internalResolveFilterString, internalResolveFilterStrings, internalResolveOneFilterString, isPassiveCommunicationsListener, listFiles, listFiles, listFolders, listFolders, listFoldersAndFiles, listFoldersAndFiles, listRoots, removeCachedRemoteFile, removeCachedRemoteFile, runLocalCommand, runLocalCommand, setHomeFolder, setListValues, setListValues, sortResolvedFilterStringObjects, toString
 
Methods inherited from class com.ibm.etools.systems.subsystems.impl.SubSystemImpl
basicSetFilterPoolReferenceManager, basicSetRemoteServerLauncher, cancelShell, checkIsConnected, clearLocalUserId, connect, connect, connect, deletingConnection, disconnect, disconnect, displayAsyncMsg, doesFilterListContentsOf, doesFilterMatch, doesFilterTypeMatch, filterEventFilterCreated, filterEventFilterPoolReferenceCreated, filterEventFilterPoolReferenceDeleted, filterEventFilterPoolReferenceRenamed, filterEventFilterPoolReferenceReset, filterEventFilterPoolReferencesRePositioned, filterEventFilterPoolReferencesReset, filterEventFilterStringCreated, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, forceUserIdToUpperCase, getActiveWorkbenchShell, getActiveWorkbenchWindow, getAdapter, getAdditionalAttributes, getCacheManager, getChildren, getCommandSubSystem, getConnectionOwnedFilterPoolName, getConnectionPrivateFilterPool, getExecutedCommands, getFactoryId, getFilterPoolReferenceManager, getFilterReferenceWithAbsoluteName, getHostName, getIBMAttribute, getIbmAttributes, getLocalUserId, getLocalUserId, getName, getParentSubSystemFactory, getPort, getPortAsInt, getPreferencesKey, getPreferencesKey, getPreferencesManager, getPrimarySubSystem, getProperties, getProperty, getQueryingMessage, getQueryingMessage, getRemoteServerLauncher, getResolvingMessage, getRunnableContext, getRunningMessage, getSaveFileName, getSettingMessage, getSettingMessage, getShell, getSystem, getSystemConnection, getSystemConnectionName, getSystemFilterPoolReferenceManager, getSystemProfile, getSystemProfileName, getSystemType, getUDActionSubsystem, getUniqueOwningSystemFilterPool, getUserId, getUserIdGen, getVendorAttribute, getVendorAttributes, hasChildren, internalCancelShell, internalConnect, internalDisconnect, internalGetProperties, internalGetProperty, internalRemoveShell, internalRunCommand, internalRunCommand, internalRunShell, internalSendCommandToShell, internalSetProperties, internalSetProperty, isConnected, isConnectionError, isHidden, isOffline, isSetAdditionalAttributes, isSetIbmAttributes, isSetVendorAttributes, isUseSSL, removeShell, renamingConnection, renamingProfile, resolveFilterString, resolveFilterString, resolveFilterString, resolveFilterString, resolveFilterStrings, resolveFilterStrings, run, runCommand, runCommand, runShell, sendCommandToShell, setAdditionalAttributes, setConnectionError, setFactoryId, setFilterPoolReferenceManager, setHidden, setIBMAttribute, setIbmAttributes, setName, setParentConnection, setParentSubSystemFactory, setPort, setProperties, setProperty, setRemoteServerLauncher, setSaveFileName, setUserId, setUserIdGen, setUseSSL, setVendorAttribute, setVendorAttributes, showConnectCancelledMessage, showConnectErrorMessage, showDisconnectCancelledMessage, showDisconnectErrorMessage, showOperationCancelledMessage, showOperationErrorMessage, showOperationMessage, supportsCaching, unsetAdditionalAttributes, unsetIbmAttributes, unsetVendorAttributes
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface com.ibm.etools.systems.subsystems.RemoteFileSubSystem
copy, copy, copy, copy, copy, copy, copyUTF8, copyUTF8, copyUTF8, copyUTF8, getHomeFolder, getLineSeparator, getParentFolderName, getParentRemoteFileSubSystemFactory, getPathSeparator, getPathSeparatorChar, getRemoteSearchResultObject, getSeparator, getSeparatorChar, listFiles, listFiles, listFolders, listFolders, listFoldersAndFiles, listFoldersAndFiles, listRoots, setHomeFolder
 
Methods inherited from interface com.ibm.etools.systems.subsystems.SubSystem
checkIsConnected, clearLocalUserId, connect, connect, connect, deletingConnection, disconnect, disconnect, doesFilterListContentsOf, doesFilterMatch, doesFilterStringListContentsOf, doesFilterStringMatch, forceUserIdToUpperCase, getAdditionalAttributes, getCacheManager, getChildren, getCommandSubSystem, getFactoryId, getFilterPoolReferenceManager, getIbmAttributes, getLocalUserId, getName, getParentSubSystemFactory, getPort, getPortAsInt, getPrimarySubSystem, getProperties, getProperty, getPropertyPage, getRemoteServerLauncher, getSaveFileName, getSystem, getSystemConnection, getSystemConnectionName, getSystemFilterPoolReferenceManager, getSystemProfile, getSystemProfileName, getTargetForFilter, getUDActionSubsystem, getUserId, getVendorAttribute, getVendorAttributes, hasChildren, isConnected, isConnectionError, isHidden, isOffline, isSetAdditionalAttributes, isSetIbmAttributes, isSetVendorAttributes, isUseSSL, renamingConnection, renamingProfile, resolveFilterString, resolveFilterString, resolveFilterString, resolveFilterString, resolveFilterStrings, resolveFilterStrings, setAdditionalAttributes, setConnectionError, setFactoryId, setFilterPoolReferenceManager, setHidden, setIbmAttributes, setName, setParentConnection, setParentSubSystemFactory, setPort, setProperties, setProperty, setRemoteServerLauncher, setSaveFileName, setUserId, setUseSSL, setVendorAttribute, setVendorAttributes, supportsCaching, unsetAdditionalAttributes, unsetIbmAttributes, unsetVendorAttributes
 
Methods inherited from interface com.ibm.etools.systems.filters.SystemFilterPoolReferenceManagerProvider
filterEventFilterCreated, filterEventFilterPoolReferenceCreated, filterEventFilterPoolReferenceDeleted, filterEventFilterPoolReferenceRenamed, filterEventFilterPoolReferenceReset, filterEventFilterPoolReferencesRePositioned, filterEventFilterPoolReferencesReset, filterEventFilterStringCreated, getUniqueOwningSystemFilterPool
 
Methods inherited from interface com.ibm.etools.systems.subsystems.IRemoteObjectResolver
getObjectWithAbsoluteName
 

Field Detail

copyright

public static final String copyright
See Also:
Constant Field Values

showHidden

protected boolean showHidden

_minerElement

protected DataElement _minerElement

_downloadDescriptor

protected DataElement _downloadDescriptor

_uploadLogElement

protected DataElement _uploadLogElement

_queryAllDescriptor

protected DataElement _queryAllDescriptor

_queryFilesDescriptor

protected DataElement _queryFilesDescriptor

_queryFoldersDescriptor

protected DataElement _queryFoldersDescriptor

_queryRemoteObjectDescriptor

protected DataElement _queryRemoteObjectDescriptor

_fsMinerVersion

protected int _fsMinerVersion

_fsMinerMajor

protected int _fsMinerMajor

_fsMinerMinor

protected int _fsMinerMinor
Constructor Detail

UniversalFileSubSystemImpl

public UniversalFileSubSystemImpl()
Constructor. Called by EMF

Method Detail

eStaticClass

protected EClass eStaticClass()

Overrides:
eStaticClass in class RemoteFileSubSystemImpl

eInverseAdd

public NotificationChain eInverseAdd(InternalEObject otherEnd,
                                     int featureID,
                                     Class baseClass,
                                     NotificationChain msgs)

Overrides:
eInverseAdd in class RemoteFileSubSystemImpl

eInverseRemove

public NotificationChain eInverseRemove(InternalEObject otherEnd,
                                        int featureID,
                                        Class baseClass,
                                        NotificationChain msgs)

Overrides:
eInverseRemove in class RemoteFileSubSystemImpl

eGet

public Object eGet(EStructuralFeature eFeature,
                   boolean resolve)

Overrides:
eGet in class RemoteFileSubSystemImpl

eSet

public void eSet(EStructuralFeature eFeature,
                 Object newValue)

Overrides:
eSet in class RemoteFileSubSystemImpl

eUnset

public void eUnset(EStructuralFeature eFeature)

Overrides:
eUnset in class RemoteFileSubSystemImpl

eIsSet

public boolean eIsSet(EStructuralFeature eFeature)

Overrides:
eIsSet in class RemoteFileSubSystemImpl

selectCommandSubSystem

protected SubSystem selectCommandSubSystem(SubSystem[] allCmdSubSystems)
Internal method to select the appropriate command subsystem when there are multiple defined for this connection. We override it to return the first command subsystem that is an instance of UniversalCmdSubSystem.

Overrides:
selectCommandSubSystem in class SubSystemImpl

getSystemManager

public AbstractSystemManager getSystemManager()
Return a singleton instance of an AbstractSystemManager subclass that manages a pool of ISystem objects, one per system connection. By default, getSystem() calls this, unless you override getSystem().

Specified by:
getSystemManager in interface SubSystem
Overrides:
getSystemManager in class SubSystemImpl
Returns:
LocalSystemManager.getTheUniversalSystemManager()

getDataStore

protected DataStore getDataStore()
Helper method to return the DataStore object needed by comm layer.


checkForNetworkErrors

protected void checkForNetworkErrors()
                              throws SystemMessageException
Check if any network errors have occured.

Throws:
SystemMessageException - if a network error has occured

getRemoteFileFactory

public IRemoteFileFactory getRemoteFileFactory()

listRoots

public IRemoteFile[] listRoots(IRemoteFileContext context)
                        throws InterruptedException
Return a list of roots/drives on the remote system

Overrides:
listRoots in class RemoteFileSubSystemImpl
Throws:
InterruptedException

search

public void search(IRemoteSearchResultConfiguration searchConfig)
Given a search configuration, searches for its results.

Specified by:
search in interface RemoteFileSubSystem
Parameters:
searchConfig - must be an instance of UniversalSearchResultConfigurationImpl.
See Also:
RemoteFileSubSystem.search(com.ibm.etools.systems.subsystems.IRemoteSearchResultConfiguration)

cancelSearch

public void cancelSearch(IRemoteSearchResultConfiguration searchConfig)
Given a search configuration, cancel the search.

Specified by:
cancelSearch in interface RemoteFileSubSystem
Parameters:
searchConfig - must be an instance of UniversalSearchResultConfigurationImpl.
See Also:
RemoteFileSubSystem.cancelSearch(com.ibm.etools.systems.subsystems.IRemoteSearchResultConfiguration)

getRemoteSearchResultConfigurationFactory

public IRemoteSearchResultConfigurationFactory getRemoteSearchResultConfigurationFactory()
Gets the search result configuration factory associated with the subsystem.

Specified by:
getRemoteSearchResultConfigurationFactory in interface RemoteFileSubSystem
Returns:
the remote search result configuration factory.
See Also:
RemoteFileSubSystem.getRemoteSearchResultConfigurationFactory()

convertObjToRemoteFile

protected IRemoteFile convertObjToRemoteFile(IRemoteFileContext context,
                                             Object obj,
                                             boolean exists)
Helper method to convert single DataElement object to IRemoteFile object


convertObjToRemoteFile

protected IRemoteFile convertObjToRemoteFile(IRemoteFileContext context,
                                             Object obj)
Helper method to convert single DataElement object to IRemoteFile object


convertObjsToRemoteFiles

protected IRemoteFile[] convertObjsToRemoteFiles(IRemoteFileContext context,
                                                 String folderFilter,
                                                 String fileFilter,
                                                 Object[] objs,
                                                 boolean isRoot,
                                                 boolean exists)
Helper method to convert DataElement objects to IRemoteFile objects when we know if it exists or not, but not whether it is a directory or not.


convertObjsToRemoteFiles

protected IRemoteFile[] convertObjsToRemoteFiles(IRemoteFileContext context,
                                                 String folderFilter,
                                                 String fileFilter,
                                                 Object[] objs,
                                                 boolean isRoot,
                                                 boolean exists,
                                                 boolean isDir)
Helper method to convert DataElement objects to IRemoteFile objects when we know if it exists or not, and whether it is a directory or not.


listFolders

public IRemoteFile[] listFolders(IRemoteFile parent,
                                 String folderNameFilter,
                                 IRemoteFileContext context)
Return a subsetted list of remote folders in the given parent folder on the remote system. This version is called by RemoteFileSubSystemImpl's resolveFilterString(s)

Overrides:
listFolders in class RemoteFileSubSystemImpl
Parameters:
parent - The parent folder to list folders in
folderNameFilter - The name pattern for subsetting the list
context - The holder of state information

listFiles

public IRemoteFile[] listFiles(IRemoteFile parent,
                               String fileNameFilter,
                               IRemoteFileContext context)
Return a list of remote files in the given folder, which match the given name pattern. This version is called by RemoteFileSubSystemImpl's resolveFilterString(s)

Overrides:
listFiles in class RemoteFileSubSystemImpl
Parameters:
parent - The parent folder to list files in
fileNameFilter - The name pattern to subset the list by, or null to return all files.
context - The holder of state information

listFoldersAndFiles

public IRemoteFile[] listFoldersAndFiles(IRemoteFile parent,
                                         String fileNameFilter,
                                         IRemoteFileContext context)
Return a list of remote folders and files in the given folder. Only the files are subsettable by name, all folders are returned. This version is called by RemoteFileSubSystemImpl's resolveFilterString(s)

Overrides:
listFoldersAndFiles in class RemoteFileSubSystemImpl
Parameters:
parent - The parent folder to list folders and files in
fileNameFilter - The name pattern to subset the file list by, or null to return all files.
context - The holder of state information

getParentFolder

public IRemoteFile getParentFolder(IRemoteFile folderOrFile)
Given a folder or file, return its parent folder object. We

Specified by:
getParentFolder in interface RemoteFileSubSystem
Overrides:
getParentFolder in class RemoteFileSubSystemImpl
Parameters:
folderOrFile - folder or file to return parent of.

getRemoteFileObject

public IRemoteFile getRemoteFileObject(String folderOrFileName)
                                throws SystemMessageException
Given a fully qualified file or folder name, return an IRemoteFile object for it.

Specified by:
getRemoteFileObject in interface RemoteFileSubSystem
Overrides:
getRemoteFileObject in class RemoteFileSubSystemImpl
Parameters:
folderOrFileName - Fully qualified folder or file name
Throws:
SystemMessageException

getRemoteFileObject

public IRemoteFile getRemoteFileObject(IRemoteFile parent,
                                       String folderOrFileName)
                                throws SystemMessageException
Given a un-qualified file or folder name, and its parent folder object, return an IRemoteFile object for the file.

Specified by:
getRemoteFileObject in interface RemoteFileSubSystem
Overrides:
getRemoteFileObject in class RemoteFileSubSystemImpl
Parameters:
parent - Folder containing the folder or file
folderOrFileName - Un-qualified folder or file name
Throws:
SystemMessageException

createFile

public IRemoteFile createFile(IRemoteFile fileToCreate)
                       throws RemoteFileSecurityException,
                              RemoteFileIOException
Create a new file, given its IRemoteFile object (these do not have to represent existing files).

Specified by:
createFile in interface RemoteFileSubSystem
Overrides:
createFile in class RemoteFileSubSystemImpl
Parameters:
fileToCreate - The object representing the file to be created.
Returns:
The same input object returned for convenience. Will throw exception if it fails.
Throws:
RemoteFileSecurityException
RemoteFileIOException
See Also:
createFolders(IRemoteFile)

createFolder

public IRemoteFile createFolder(IRemoteFile folderToCreate)
                         throws RemoteFileSecurityException,
                                RemoteFileIOException
Create a new folder, given its IRemoteFile object (these do not have to represent existing folders)

Specified by:
createFolder in interface RemoteFileSubSystem
Overrides:
createFolder in class RemoteFileSubSystemImpl
Parameters:
folderToCreate - The object representing the folder to be created.
Returns:
The same input object returned for convenience. Will throw exception if it fails.
Throws:
RemoteFileSecurityException
RemoteFileIOException
See Also:
createFolders(IRemoteFile)

markCachedStale

public void markCachedStale(String absolutePath)

createFolders

public IRemoteFile createFolders(IRemoteFile folderToCreate)
                          throws RemoteFileSecurityException,
                                 RemoteFileIOException
Given an IRemoteFile for a folder, this will create that folder and any missing parent folders in its path. Use getParentFolder to get the parent object of your file or folder in order to call this method.

Specified by:
createFolders in interface RemoteFileSubSystem
Overrides:
createFolders in class RemoteFileSubSystemImpl
Parameters:
folderToCreate - The object representing the folder to be created, along with its parents.
Returns:
The same input object returned for convenience. Will throw exception if it fails.
Throws:
RemoteFileSecurityException
RemoteFileIOException
See Also:
getParentFolder(IRemoteFile)

delete

public boolean delete(IRemoteFile folderOrFile)
               throws RemoteFolderNotEmptyException,
                      RemoteFileSecurityException,
                      RemoteFileIOException
Delete the given remote file or folder.

Specified by:
delete in interface RemoteFileSubSystem
Overrides:
delete in class RemoteFileSubSystemImpl
Parameters:
folderOrFile - represents the object to be deleted.
Returns:
false if the given folder/file didn't exist to begin with, else true. Throws an exception if anything fails.
Throws:
RemoteFolderNotEmptyException
RemoteFileSecurityException
RemoteFileIOException

rename

public boolean rename(IRemoteFile folderOrFile,
                      String newName)
               throws RemoteFileIOException,
                      RemoteFileSecurityException
Rename the given remote file or folder. This renames it in memory and, iff it exists, on disk.

Specified by:
rename in interface RemoteFileSubSystem
Overrides:
rename in class RemoteFileSubSystemImpl
Parameters:
folderOrFile - represents the object to be renamed.
newName - new name to give it.
Returns:
false if the given folder/file didn't exist on disk (still renamed in memory), else true. Throws an exception if anything fails.
Throws:
RemoteFileIOException
RemoteFileSecurityException

setLastModified

public boolean setLastModified(IRemoteFile folderOrFile,
                               long newDate)
                        throws RemoteFileSecurityException,
                               RemoteFileIOException
Set the last modified date for the given file or folder. Like a Unix "touch" operation. Folder or file must exist on disk for this to succeed.

Specified by:
setLastModified in interface RemoteFileSubSystem
Overrides:
setLastModified in class RemoteFileSubSystemImpl
Parameters:
folderOrFile - represents the object to be renamed.
newDate - new date, in milliseconds from epoch, to assign.
Returns:
false if the given folder/file didn't exist on disk (operation fails), else true. Throws an exception if anything fails.
Throws:
RemoteFileSecurityException
RemoteFileIOException

setReadOnly

public boolean setReadOnly(IRemoteFile folderOrFile)
                    throws RemoteFileSecurityException,
                           RemoteFileIOException
Set this file to be readonly. Folder or file must exist on disk for this to succeed.

Specified by:
setReadOnly in interface RemoteFileSubSystem
Overrides:
setReadOnly in class RemoteFileSubSystemImpl
Parameters:
folderOrFile - represents the object to be renamed.
Returns:
false if the given folder/file didn't exist on disk (operation fails), else true. Throws an exception if anything fails.
Throws:
RemoteFileSecurityException
RemoteFileIOException

getFileSystemMinerElement

protected DataElement getFileSystemMinerElement()

getFileSystemMinerVersion

protected int getFileSystemMinerVersion()

getDownloadDescriptor

protected DataElement getDownloadDescriptor(DataElement remoteElement)

getQueryAllDescriptor

protected DataElement getQueryAllDescriptor(DataElement remoteElement)

getQueryFilesDescriptor

protected DataElement getQueryFilesDescriptor(DataElement remoteElement)

getQueryFoldersDescriptor

protected DataElement getQueryFoldersDescriptor(DataElement remoteElement)

getQueryRemoteObjectDescriptor

protected DataElement getQueryRemoteObjectDescriptor(DataElement remoteElement)

copy

public void copy(IRemoteFile source,
                 String destination,
                 String encoding,
                 IProgressMonitor monitor)
          throws RemoteFileSecurityException,
                 RemoteFileIOException
Get the remote file and save it locally. The file is saved in the encoding specified.

Specified by:
copy in interface RemoteFileSubSystem
Parameters:
source - remote file that represents the file to be obtained
destination - the absolute path of the local file
encoding - the encoding of the local file
monitor - progress monitor
Throws:
RemoteFileSecurityException
RemoteFileIOException

getDataStoreRoot

protected String getDataStoreRoot()

prepareForDownload

protected String prepareForDownload(String localPath)

setDataStoreRoot

protected void setDataStoreRoot(String root)

copy

public void copy(String source,
                 IRemoteFile destination,
                 String encoding,
                 IProgressMonitor monitor)
          throws RemoteFileSecurityException,
                 RemoteFileIOException
Put the local copy of the remote file back to the remote location. The file is assumed to be in the encoding specified

Specified by:
copy in interface RemoteFileSubSystem
Parameters:
source - the absolute path of the local copy
destination - remote file that represents the file on the server
encoding - the encoding of the local copy
monitor - the progress monitor
Throws:
RemoteFileSecurityException
RemoteFileIOException

getUploadBufferSize

public int getUploadBufferSize()

getDownloadBufferSize

public int getDownloadBufferSize()

copyLocalToRemote

public void copyLocalToRemote(String source,
                              String destination,
                              IProgressMonitor monitor)
                       throws RemoteFileSecurityException,
                              RemoteFileIOException
Put the local copy of the remote file back to the remote location. The file is assumed to be in the encoding of the local operating system

Specified by:
copyLocalToRemote in interface RemoteFileSubSystem
Overrides:
copyLocalToRemote in class RemoteFileSubSystemImpl
Parameters:
source - the absolute path of the local copy
destination - remote file that represents the file on the server
monitor - the progress monitor
Throws:
RemoteFileSecurityException
RemoteFileIOException

copyLocalToRemote

public void copyLocalToRemote(String source,
                              String srcEncoding,
                              String remotePath,
                              String rmtEncoding,
                              IProgressMonitor monitor)
                       throws RemoteFileSecurityException,
                              RemoteFileIOException
Put the local copy of the remote file back to the remote location. The file is assumed to be in the encoding specified

Specified by:
copyLocalToRemote in interface RemoteFileSubSystem
Overrides:
copyLocalToRemote in class RemoteFileSubSystemImpl
Parameters:
source - the absolute path of the local copy
srcEncoding - The encoding of the local copy
remotePath - remote file that represents the file on the server
rmtEncoding - The encoding of the remote file.
monitor - the progress monitor
Throws:
RemoteFileSecurityException
RemoteFileIOException

copy

public void copy(InputStream stream,
                 long totalBytes,
                 IRemoteFile destination,
                 String encoding,
                 IProgressMonitor monitor)
          throws RemoteFileSecurityException,
                 RemoteFileIOException
Description copied from interface: RemoteFileSubSystem
Put local data to a remote location. The local data is assumed to be in the encoding specified.

Specified by:
copy in interface RemoteFileSubSystem
Parameters:
stream - the input stream containing the local data.
totalBytes - the total number of bytes in the stream, or -1 if unknown. If -1 is specified, then the progress monitor must be null.
destination - remote file that represents the file on the server.
encoding - the encoding of the local data, or null to specify binary.
monitor - the progress monitor.
Throws:
RemoteFileSecurityException
RemoteFileIOException
See Also:
RemoteFileSubSystem.copy(java.io.InputStream, long, com.ibm.etools.systems.subsystems.IRemoteFile, java.lang.String, org.eclipse.core.runtime.IProgressMonitor)

copyLocalToRemote

public void copyLocalToRemote(InputStream stream,
                              long totalBytes,
                              String srcEncoding,
                              String remotePath,
                              String rmtEncoding,
                              IProgressMonitor monitor)
                       throws RemoteFileSecurityException,
                              RemoteFileIOException
Uploads local data to a remote file.

Parameters:
stream - the input stream representing the local data.
totalBytes - the total number of bytes to upload, or -1 if unknown. If -1 is specified, then the progress monitor must be null.
srcEncoding - the source encoding, or null for binary.
remotePath - path of the remote file.
rmtEncoding - the remote encoding.
monitor - the progress monitor.
Throws:
RemoteFileSecurityException
RemoteFileIOException

showUploadFailedMessage

protected void showUploadFailedMessage(FileTransferStatusListener listener,
                                       String source)
                                throws RemoteFileIOException
Throws:
RemoteFileIOException

getRemoteEncoding

public String getRemoteEncoding()
Get the encoding of the remote machine

Specified by:
getRemoteEncoding in interface RemoteFileSubSystem
Returns:
the encoding

isCaseSensitive

public boolean isCaseSensitive()
Return true if file names are case-sensitive. Used when doing name or type filtering Default is isUnixStyle from factory

Specified by:
isCaseSensitive in interface RemoteFileSubSystem
Overrides:
isCaseSensitive in class RemoteFileSubSystemImpl

setAttributes

public void setAttributes(DataElement deObj,
                          String fileNameFilter,
                          boolean showHidden)
The attributes sent to the miner - required for the query. These are sent as a StringBuffer

The StringBuffer sends the attributes required by the miner for the query in the following order


setSearchAttributes

public ArrayList setSearchAttributes(String textString,
                                     boolean isCaseSensitive,
                                     boolean isTextRegex,
                                     String fileNamesString,
                                     boolean isFileNamesRegex,
                                     boolean includeArchives,
                                     boolean includeSubfolders,
                                     String classificationString,
                                     boolean showHidden)

getUniversalCmdSubSystem

public UniversalCmdSubSystemImpl getUniversalCmdSubSystem()
Retrieve the peer Universal command subsystem for for this connection


copy

public boolean copy(IRemoteFile sourceFolderOrFile,
                    IRemoteFile targetFolder,
                    String newName,
                    IProgressMonitor monitor)
             throws RemoteFileSecurityException,
                    RemoteFileIOException
Description copied from interface: RemoteFileSubSystem
Copy a file or folder to a new target parent folder.

Specified by:
copy in interface RemoteFileSubSystem
Parameters:
sourceFolderOrFile - The file or folder to copy
targetFolder - The folder to copy to. No guarantee it is on the same system, so be sure to check getSystemConnection()!
newName - The new name for the copied file or folder
Returns:
false true iff the copy succeeded
Throws:
RemoteFileSecurityException
RemoteFileIOException
See Also:
RemoteFileSubSystemImpl#copy(IRemoteFile, IRemoteFile, String)

move

public boolean move(IRemoteFile sourceFolderOrFile,
                    IRemoteFile targetFolder,
                    String newName)
             throws RemoteFileSecurityException,
                    RemoteFileIOException
Description copied from interface: RemoteFileSubSystem
Move a file or folder to a new target parent folder.

Specified by:
move in interface RemoteFileSubSystem
Overrides:
move in class RemoteFileSubSystemImpl
Parameters:
sourceFolderOrFile - The file or folder to move
targetFolder - The folder to move to. No guarantee it is on the same system, so be sure to check getSystemConnection()!
newName - The new name for the moved file or folder
Returns:
true iff the move succeeded
Throws:
RemoteFileSecurityException
RemoteFileIOException
See Also:
RemoteFileSubSystemImpl.move(IRemoteFile, IRemoteFile, String)

isSpecialChar

protected boolean isSpecialChar(char c)
Checks whether the given character is a special character in the shell. A special character is '$', '`', '"' and '\'.

Parameters:
c - the character to check.
Returns:
true if the character is a special character, false otherwise.

getQualifiedClassName

public String getQualifiedClassName(IRemoteFile classFile)

findUploadStatusFor

protected DataElement findUploadStatusFor(String remotePath)

findUploadLog

protected DataElement findUploadLog()

getLanguageUtilityFactory

public ILanguageUtilityFactory getLanguageUtilityFactory()
Returns an instance of UniversalLanguageUtilityFactory.

Specified by:
getLanguageUtilityFactory in interface RemoteFileSubSystem
Overrides:
getLanguageUtilityFactory in class RemoteFileSubSystemImpl
See Also:
RemoteFileSubSystem.getLanguageUtilityFactory()

getUnusedPort

public int getUnusedPort()
Description copied from interface: RemoteFileSubSystem
Returns an unused port number on the remote host that could be used by any tool on the host.

Specified by:
getUnusedPort in interface RemoteFileSubSystem
Overrides:
getUnusedPort in class RemoteFileSubSystemImpl
See Also:
RemoteFileSubSystem.getUnusedPort()

getLocalAddress

public InetAddress getLocalAddress()
Gets an unused port on the remote host, connects to it and asks the socket for the local connection. If the connect fails, we try to connect to some well-known ports, such as echo, telnet, ssh and web server. The idea is to try to create a socket connection to an open port on the remote host, and get the local address from the socket.

Specified by:
getLocalAddress in interface RemoteFileSubSystem
Overrides:
getLocalAddress in class RemoteFileSubSystemImpl
See Also:
RemoteFileSubSystem.getLocalAddress()

getWellKnownRemotePorts

protected int[] getWellKnownRemotePorts()
Gets an array of well known ports on the remote system. This includes the following ports in order: SSH (port 22), Telnet (port 23), FTP (port 21), HTTP (port 80) and Echo (port 7).

Returns:
an array of well known ports.

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.