Bug 209552 - [api][breaking] remove deprecated file service API, rename multi to multiple and change UniversalFileTransferUtility APIs to use download and upload
Summary: [api][breaking] remove deprecated file service API, rename multi to multiple ...
Status: VERIFIED FIXED
Alias: None
Product: Target Management
Classification: Tools
Component: RSE (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 3.0 M4   Edit
Assignee: David McKnight CLA
QA Contact: Martin Oberhuber CLA
URL:
Whiteboard:
Keywords: api
Depends on: 204307 207178
Blocks:
  Show dependency tree
 
Reported: 2007-11-12 16:29 EST by David McKnight CLA
Modified: 2007-11-27 15:35 EST (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description David McKnight CLA 2007-11-12 16:29:03 EST
Currently the APIs for UniversalFileTransferUtility consist of:


compressedCopyRemoteResourceToWorkspace(IRemoteFile, IProgressMonitor)
compressedCopyWorkspaceResourceToRemote(IContainer, IRemoteFile, IProgressMonitor)
copyRemoteFileToWorkspace(File, IProgressMonitor)
copyRemoteFileToWorkspace(IRemoteFile, IProgressMonitor)
copyRemoteResourcesToWorkspace(SystemRemoteResourceSet, IProgressMonitor)
copyRemoteResourcesToWorkspaceMultiple(SystemRemoteResourceSet, IProgressMonitor)
copyRemoteResourceToWorkspace(File, IProgressMonitor)
copyRemoteResourceToWorkspace(IRemoteFile, IProgressMonitor)
copyWorkspaceResourcesToRemote(SystemWorkspaceResourceSet, IRemoteFile, IProgressMonitor, boolean)
copyWorkspaceResourceToRemote(IResource, IRemoteFile, IProgressMonitor)
copyWorkspaceResourceToRemote(IResource, IRemoteFile, IProgressMonitor, boolean)

I think these would be much easier to understand if we used the something like this:

compressedDownloadToWorkspace(IRemoteFile, IProgressMonitor)
compressedUploadFromWorkspace(IContainer, IRemoteFile, IProgressMonitor)
downloadFileToWorkspace(File, IProgressMonitor)
downloadFileToWorkspace(IRemoteFile, IProgressMonitor)
downloadResourcesToWorkspace(SystemRemoteResourceSet, IProgressMonitor)
downloadResourcesToWorkspaceMultiple(SystemRemoteResourceSet, IProgressMonitor)
downloadResourceToWorkspace(File, IProgressMonitor)
downloadResourceToWorkspace(IRemoteFile, IProgressMonitor)
uploadFromWorkspace(SystemWorkspaceResourceSet, IRemoteFile, IProgressMonitor, boolean)
uploadFromWorkspace(IResource, IRemoteFile, IProgressMonitor)
uploadFromWorkspace(IResource, IRemoteFile, IProgressMonitor, boolean)
Comment 1 David McKnight CLA 2007-11-12 16:31:30 EST
Any thoughts on this?
Comment 2 David McKnight CLA 2007-11-14 14:22:37 EST
I'll also use this defect to rename the file service apis, downloadMulti() and uploadMulti(), to downloadMultiple() and uploadMultiple().
Comment 3 David McKnight CLA 2007-11-15 14:13:57 EST
In addition, I'll get rid of the deprecated IFileService and IRemoteFileSubSystem APIs.
Comment 4 David McKnight CLA 2007-11-15 14:43:58 EST
I've committed the changes to this.
Comment 5 Martin Oberhuber CLA 2007-11-21 14:57:51 EST
I'm wondering whether there is a need to dupliate the IFileService#FILE_TYPE_* constants in IRemoteFileSubSystem.java for easier consumption with its API... how strong do we want the separation between subsystem and service?

Currently it looks like even if somebody wanted to implement an IRemoteFileSubsystem without any Service underneath it, there is still a dependency to IFileService. Is that OK?
Comment 6 Martin Oberhuber CLA 2007-11-21 14:59:49 EST
Probably not since IFileServiceSubSystem is in the same plugin as IRemoteFileSubSystem and also requires IFileService already, so the dependency is there anyways.
Comment 7 David McKnight CLA 2007-11-23 08:52:13 EST
Yeah, because of the dependency of FileServiceSubSystem on IFileService, I think the constants are in the right place and there's no need to duplicate them.