diff --git a/rse/plugins/org.eclipse.rse.files.ui/src/org/eclipse/rse/files/ui/resources/SystemEditableRemoteFile.java b/rse/plugins/org.eclipse.rse.files.ui/src/org/eclipse/rse/files/ui/resources/SystemEditableRemoteFile.java
index 8a0e552fb79..8dcb5629d7e 100644
--- a/rse/plugins/org.eclipse.rse.files.ui/src/org/eclipse/rse/files/ui/resources/SystemEditableRemoteFile.java
+++ b/rse/plugins/org.eclipse.rse.files.ui/src/org/eclipse/rse/files/ui/resources/SystemEditableRemoteFile.java
@@ -111,10 +111,8 @@ public class SystemEditableRemoteFile implements ISystemEditableRemoteObject, IP
super("Download"); // TODO - need to externalize //$NON-NLS-1$
}
-
-
/**
- * @see WorkspaceModifyOperation#execute(IProgressMonitor)
+ *
*/
protected void execute(IProgressMonitor monitor) throws CoreException, InvocationTargetException, InterruptedException
{
@@ -600,7 +598,7 @@ public class SystemEditableRemoteFile implements ISystemEditableRemoteObject, IP
return false;
}
- subsystem.downloadUTF8(remoteFile, localPath, monitor);
+ subsystem.download(remoteFile, localPath, SystemEncodingUtil.ENCODING_UTF_8, monitor);
if (monitor.isCanceled())
{
return false;
@@ -676,7 +674,7 @@ public class SystemEditableRemoteFile implements ISystemEditableRemoteObject, IP
subsystem.connect();
}
- subsystem.uploadUTF8(localPath, remoteFile, null);
+ subsystem.upload(localPath, remoteFile, SystemEncodingUtil.ENCODING_UTF_8, null);
// update timestamp
IFile file = getLocalResource();
diff --git a/rse/plugins/org.eclipse.rse.files.ui/src/org/eclipse/rse/files/ui/resources/SystemUniversalTempFileListener.java b/rse/plugins/org.eclipse.rse.files.ui/src/org/eclipse/rse/files/ui/resources/SystemUniversalTempFileListener.java
index 38f2d58a513..9c4ea2fea0c 100644
--- a/rse/plugins/org.eclipse.rse.files.ui/src/org/eclipse/rse/files/ui/resources/SystemUniversalTempFileListener.java
+++ b/rse/plugins/org.eclipse.rse.files.ui/src/org/eclipse/rse/files/ui/resources/SystemUniversalTempFileListener.java
@@ -26,6 +26,7 @@ import org.eclipse.rse.internal.files.ui.resources.SystemRemoteEditManager;
import org.eclipse.rse.model.ISystemResourceChangeEvents;
import org.eclipse.rse.model.SystemRegistry;
import org.eclipse.rse.model.SystemResourceChangeEvent;
+import org.eclipse.rse.services.clientserver.SystemEncodingUtil;
import org.eclipse.rse.services.files.RemoteFileIOException;
import org.eclipse.rse.services.files.RemoteFileSecurityException;
import org.eclipse.rse.subsystems.files.core.subsystems.IRemoteFile;
@@ -229,7 +230,7 @@ public class SystemUniversalTempFileListener extends SystemTempFileListener
try
{
// upload our pending changes to the remote file
- fs.uploadUTF8(tempFile, remoteFile,monitor);
+ fs.upload(tempFile.getLocation().makeAbsolute().toOSString(), remoteFile, SystemEncodingUtil.ENCODING_UTF_8, monitor);
}
catch (RemoteFileSecurityException e)
diff --git a/rse/plugins/org.eclipse.rse.files.ui/src/org/eclipse/rse/files/ui/resources/UniversalFileTransferUtility.java b/rse/plugins/org.eclipse.rse.files.ui/src/org/eclipse/rse/files/ui/resources/UniversalFileTransferUtility.java
index c62c1a4a45c..0209ba61583 100644
--- a/rse/plugins/org.eclipse.rse.files.ui/src/org/eclipse/rse/files/ui/resources/UniversalFileTransferUtility.java
+++ b/rse/plugins/org.eclipse.rse.files.ui/src/org/eclipse/rse/files/ui/resources/UniversalFileTransferUtility.java
@@ -166,7 +166,7 @@ public class UniversalFileTransferUtility
// copy remote file to workspace
SystemUniversalTempFileListener listener = SystemUniversalTempFileListener.getListener();
listener.addIgnoreFile(tempFile);
- srcFS.download(srcFileOrFolder, tempFile, SystemEncodingUtil.ENCODING_UTF_8, monitor);
+ srcFS.download(srcFileOrFolder, tempFile.getLocation().makeAbsolute().toOSString(), SystemEncodingUtil.ENCODING_UTF_8, monitor);
listener.removeIgnoreFile(tempFile);
if (!tempFile.exists() && !tempFile.isSynchronized(IResource.DEPTH_ZERO))
{
@@ -1387,7 +1387,7 @@ public class UniversalFileTransferUtility
newPath = newTargetParent.getAbsolutePath() + targetFS.getSeparator() + destinationArchive.getName();
// copy local zip to remote
- targetFS.upload(destinationArchive.getAbsolutePath(), newPath, monitor);
+ targetFS.upload(destinationArchive.getAbsolutePath(), SystemEncodingUtil.ENCODING_UTF_8, newPath, System.getProperty("file.encoding"), monitor); //$NON-NLS-1$
IRemoteFile remoteArchive = targetFS.getRemoteFileObject(newPath);
monitor.subTask(FileResources.RESID_SUPERTRANSFER_PROGMON_SUBTASK_EXTRACT);
@@ -1545,7 +1545,7 @@ public class UniversalFileTransferUtility
// DKM - use parent folder as dest
dest = new File(targetResource.getParent().getLocation().toOSString() + File.separator + name);
- sourceFS.download(cpdest, dest, monitor);
+ sourceFS.download(cpdest, dest.getAbsolutePath(), System.getProperty("file.encoding"), monitor); //$NON-NLS-1$
ISystemArchiveHandler handler = ArchiveHandlerManager.getInstance().getRegisteredHandler(dest);
diff --git a/rse/plugins/org.eclipse.rse.files.ui/src/org/eclipse/rse/internal/files/ui/actions/SystemCopyRemoteFileAction.java b/rse/plugins/org.eclipse.rse.files.ui/src/org/eclipse/rse/internal/files/ui/actions/SystemCopyRemoteFileAction.java
index b28872628cb..4b8c2a053ee 100644
--- a/rse/plugins/org.eclipse.rse.files.ui/src/org/eclipse/rse/internal/files/ui/actions/SystemCopyRemoteFileAction.java
+++ b/rse/plugins/org.eclipse.rse.files.ui/src/org/eclipse/rse/internal/files/ui/actions/SystemCopyRemoteFileAction.java
@@ -35,6 +35,7 @@ import org.eclipse.rse.files.ui.dialogs.SystemRemoteFolderDialog;
import org.eclipse.rse.internal.files.ui.resources.SystemRemoteEditManager;
import org.eclipse.rse.internal.ui.view.SystemView;
import org.eclipse.rse.model.ISystemRemoteChangeEvents;
+import org.eclipse.rse.services.clientserver.SystemEncodingUtil;
import org.eclipse.rse.services.clientserver.messages.SystemMessage;
import org.eclipse.rse.services.clientserver.messages.SystemMessageException;
import org.eclipse.rse.subsystems.files.core.subsystems.IRemoteFile;
@@ -252,8 +253,8 @@ public class SystemCopyRemoteFileAction extends SystemBaseCopyAction
String tempFile = path.toString();
- srcFS.download(srcFileOrFolder, tempFile, null);
- targetFS.upload(tempFile, newPath, null);
+ srcFS.download(srcFileOrFolder, tempFile, SystemEncodingUtil.ENCODING_UTF_8, null);
+ targetFS.upload(tempFile, SystemEncodingUtil.ENCODING_UTF_8, newPath, System.getProperty("file.encoding"), null); //$NON-NLS-1$
}
else
{
diff --git a/rse/plugins/org.eclipse.rse.files.ui/src/org/eclipse/rse/internal/files/ui/actions/SystemUploadConflictAction.java b/rse/plugins/org.eclipse.rse.files.ui/src/org/eclipse/rse/internal/files/ui/actions/SystemUploadConflictAction.java
index 32237242d83..e212465955e 100644
--- a/rse/plugins/org.eclipse.rse.files.ui/src/org/eclipse/rse/internal/files/ui/actions/SystemUploadConflictAction.java
+++ b/rse/plugins/org.eclipse.rse.files.ui/src/org/eclipse/rse/internal/files/ui/actions/SystemUploadConflictAction.java
@@ -32,6 +32,7 @@ import org.eclipse.rse.files.ui.resources.SystemEditableRemoteFile;
import org.eclipse.rse.files.ui.resources.SystemIFileProperties;
import org.eclipse.rse.model.ISystemResourceChangeEvents;
import org.eclipse.rse.model.SystemResourceChangeEvent;
+import org.eclipse.rse.services.clientserver.SystemEncodingUtil;
import org.eclipse.rse.services.clientserver.messages.SystemMessage;
import org.eclipse.rse.services.clientserver.messages.SystemMessageException;
import org.eclipse.rse.services.files.RemoteFileIOException;
@@ -102,7 +103,7 @@ public class SystemUploadConflictAction extends SystemBaseAction implements Runn
try
{
// copy temp file to remote system
- fs.uploadUTF8(_tempFile, _saveasFile, monitor);
+ fs.upload(_tempFile.getLocation().makeAbsolute().toOSString(), _saveasFile, SystemEncodingUtil.ENCODING_UTF_8, monitor);
// set original time stamp to 0 so that file will be overwritten next download
SystemIFileProperties properties = new SystemIFileProperties(_tempFile);
@@ -137,7 +138,7 @@ public class SystemUploadConflictAction extends SystemBaseAction implements Runn
SystemIFileProperties properties = new SystemIFileProperties(_tempFile);
// download remote version
- fs.downloadUTF8(_remoteFile, _tempFile, monitor);
+ fs.download(_remoteFile, _tempFile.getLocation().makeAbsolute().toOSString(), SystemEncodingUtil.ENCODING_UTF_8, monitor);
properties.setRemoteFileTimeStamp(_remoteFile.getLastModified());
//properties.setRemoteFileTimeStamp(-1);
@@ -177,7 +178,7 @@ public class SystemUploadConflictAction extends SystemBaseAction implements Runn
{
IRemoteFileSubSystem fs = _remoteFile.getParentRemoteFileSubSystem();
SystemIFileProperties properties = new SystemIFileProperties(_tempFile);
- fs.uploadUTF8(_tempFile, _remoteFile, monitor);
+ fs.upload(_tempFile.getLocation().makeAbsolute().toOSString(), _remoteFile, SystemEncodingUtil.ENCODING_UTF_8, monitor);
_remoteFile.markStale(true);
_remoteFile = fs.getRemoteFileObject(_remoteFile.getAbsolutePath());
properties.setRemoteFileTimeStamp(_remoteFile.getLastModified());
diff --git a/rse/plugins/org.eclipse.rse.files.ui/src/org/eclipse/rse/internal/files/ui/view/SystemViewRemoteFileAdapter.java b/rse/plugins/org.eclipse.rse.files.ui/src/org/eclipse/rse/internal/files/ui/view/SystemViewRemoteFileAdapter.java
index 673b78f792e..3634d3780a2 100644
--- a/rse/plugins/org.eclipse.rse.files.ui/src/org/eclipse/rse/internal/files/ui/view/SystemViewRemoteFileAdapter.java
+++ b/rse/plugins/org.eclipse.rse.files.ui/src/org/eclipse/rse/internal/files/ui/view/SystemViewRemoteFileAdapter.java
@@ -84,6 +84,7 @@ import org.eclipse.rse.model.SystemRemoteResourceSet;
import org.eclipse.rse.model.SystemResourceChangeEvent;
import org.eclipse.rse.services.clientserver.PathUtility;
import org.eclipse.rse.services.clientserver.StringCompare;
+import org.eclipse.rse.services.clientserver.SystemEncodingUtil;
import org.eclipse.rse.services.clientserver.SystemSearchString;
import org.eclipse.rse.services.clientserver.archiveutils.ArchiveHandlerManager;
import org.eclipse.rse.services.clientserver.messages.SystemMessage;
@@ -2167,7 +2168,7 @@ public class SystemViewRemoteFileAdapter
String newPath = newPathBuf.toString();
monitor.subTask(copyMessage.getLevelOneText());
- targetFS.upload(srcFileOrFolder.getAbsolutePath(), newPath, monitor);
+ targetFS.upload(srcFileOrFolder.getAbsolutePath(), SystemEncodingUtil.ENCODING_UTF_8, newPath, System.getProperty("file.encoding"), monitor); //$NON-NLS-1$
result = targetFS.getRemoteFileObject(targetFolder, name);
return result;
diff --git a/rse/plugins/org.eclipse.rse.subsystems.files.core/src/org/eclipse/rse/subsystems/files/core/servicesubsystem/FileServiceSubSystem.java b/rse/plugins/org.eclipse.rse.subsystems.files.core/src/org/eclipse/rse/subsystems/files/core/servicesubsystem/FileServiceSubSystem.java
index 1b70e073a90..20d26197c0d 100644
--- a/rse/plugins/org.eclipse.rse.subsystems.files.core/src/org/eclipse/rse/subsystems/files/core/servicesubsystem/FileServiceSubSystem.java
+++ b/rse/plugins/org.eclipse.rse.subsystems.files.core/src/org/eclipse/rse/subsystems/files/core/servicesubsystem/FileServiceSubSystem.java
@@ -551,25 +551,6 @@ public final class FileServiceSubSystem extends RemoteFileSubSystem implements I
}
}
- public void upload(InputStream stream, long totalBytes, IRemoteFile destination, String encoding, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException
- {
- String remoteParentPath = destination.getParentPath();
- String remoteFileName = destination.getName();
- String hostEncoding = getRemoteEncoding(); // default host encoding
- boolean isBinary = isBinary(encoding, hostEncoding, destination.getAbsolutePath());
- try
- {
- getFileService().upload(monitor, stream, remoteParentPath, remoteFileName, isBinary, hostEncoding);
- }
- catch (SystemMessageException e)
- {
- SystemMessageDialog dlg = new SystemMessageDialog(getShell(), e.getSystemMessage());
- dlg.open();
- }
- }
-
-
-
public boolean copy(IRemoteFile sourceFolderOrFile, IRemoteFile targetFolder, String newName, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException
{
IFileService service = getFileService();
diff --git a/rse/plugins/org.eclipse.rse.subsystems.files.core/src/org/eclipse/rse/subsystems/files/core/subsystems/IRemoteFileSubSystem.java b/rse/plugins/org.eclipse.rse.subsystems.files.core/src/org/eclipse/rse/subsystems/files/core/subsystems/IRemoteFileSubSystem.java
index f593268d639..fd1a9ddc8cf 100644
--- a/rse/plugins/org.eclipse.rse.subsystems.files.core/src/org/eclipse/rse/subsystems/files/core/subsystems/IRemoteFileSubSystem.java
+++ b/rse/plugins/org.eclipse.rse.subsystems.files.core/src/org/eclipse/rse/subsystems/files/core/subsystems/IRemoteFileSubSystem.java
@@ -16,7 +16,7 @@
*******************************************************************************/
package org.eclipse.rse.subsystems.files.core.subsystems;
-import java.io.File;
+
import java.io.InputStream;
import java.io.OutputStream;
import java.net.InetAddress;
@@ -406,19 +406,6 @@ public interface IRemoteFileSubSystem extends ISubSystem {
* @return false true iff all copies succeeded
*/
public boolean copyBatch(IRemoteFile[] sourceFolderOrFile, IRemoteFile targetFolder, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException;
-
-
- /**
- * Get the remote file and save it locally. The file is saved in the encoding
- * of the operating system. Two exceptions: if the remote file is binary, encoding does not apply.
- * If the remote file is a XML file, then it will be copied to local in the encoding
- * specified in the XML declaration, or as determined from the XML specification.
- * @param source remote file that represents the file to be obtained
- * @param destination the absolute path of the local file
- * @param monitor the progress monitor
- */
- public void download(IRemoteFile source, String destination, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException;
-
/**
* Get the remote file and save it locally. The file is saved in the encoding
@@ -430,114 +417,7 @@ public interface IRemoteFileSubSystem extends ISubSystem {
* @param encoding the encoding of the local file
* @param monitor the progress monitor
*/
- public void download(IRemoteFile source, String destination, String encoding, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException;
-
-
- /**
- * Get the remote file and save it locally. The file is saved in UTF-8 encoding.
- * Two exceptions: if the remote file is binary, encoding does not apply.
- * If the remote file is a XML file, then it will be copied to local in the encoding
- * specified in the XML declaration, or as determined from the XML specification.
- * This is a recommended method to use for file transfer.
- * @param source remote file that represents the file to be obtained
- * @param destination the absolute path of the local file
- * @param monitor the progress monitor
- */
- public void downloadUTF8(IRemoteFile source, String destination, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException;
-
-
- /**
- * Get the remote file and save it locally. The file is saved in the encoding
- * of the operating system. Two exceptions: if the remote file is binary, encoding does not apply.
- * If the remote file is a XML file, then it will be copied to local in the encoding
- * specified in the XML declaration, or as determined from the XML specification.
- * @param source remote file that represents the file to be obtained
- * @param destination the local file
- * @param monitor the progress monitor
- */
- public void download(IRemoteFile source, File destination, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException;
-
-
- /**
- * Get the remote file and save it locally. The file is saved in the encoding
- * specified. Two exceptions: if the remote file is binary, encoding does not apply.
- * If the remote file is a XML file, then it will be copied to local in the encoding
- * specified in the XML declaration, or as determined from the XML specification.
- * @param source remote file that represents the file to be obtained
- * @param destination the local file
- * @param encoding the encoding of the local file
- * @param monitor the progress monitor
- */
- public void download(IRemoteFile source, File destination, String encoding, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException;
-
-
- /**
- * Get the remote file and save it locally. The file is saved in UTF-8 encoding.
- * Two exceptions: if the remote file is binary, encoding does not apply.
- * If the remote file is a XML file, then it will be copied to local in the encoding
- * specified in the XML declaration, or as determined from the XML specification.
- * This is a recommended method to use for file transfer.
- * @param source remote file that represents the file to be obtained
- * @param destination the local file
- * @param monitor the progress monitor
- */
- public void downloadUTF8(IRemoteFile source, File destination, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException;
-
-
- /**
- * Get the remote file and save it locally. The file is saved in the encoding
- * of the operating system. Two exceptions: if the remote file is binary, encoding does not apply.
- * If the remote file is a XML file, then it will be copied to local in the encoding
- * specified in the XML declaration, or as determined from the XML specification.
- * @param source remote file that represents the file to be obtained
- * @param destination the local file
- * @param monitor the progress monitor
- */
- public void download(IRemoteFile source, IFile destination, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException;
-
-
- /**
- * Get the remote file and save it locally. The file is saved in the encoding
- * specified. Two exceptions: if the remote file is binary, encoding does not apply.
- * If the remote file is a XML file, then it will be copied to local in the encoding
- * specified in the XML declaration, or as determined from the XML specification.
- * @param source remote file that represents the file to be obtained
- * @param destination the local file
- * @param encoding the encoding of the local file
- * @param monitor the progress monitor
- */
- public void download(IRemoteFile source, IFile destination, String encoding, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException;
-
-
- /**
- * Get the remote file and save it locally. The file is saved in UTF-8 encoding.
- * Two exceptions: if the remote file is binary, encoding does not apply.
- * If the remote file is a XML file, then it will be copied to local in the encoding
- * specified in the XML declaration, or as determined from the XML specification.
- * This is a recommended method to use for file transfer.
- * @param source remote file that represents the file to be obtained
- * @param destination the local file
- * @param monitor the progress monitor
- */
- public void downloadUTF8(IRemoteFile source, IFile destination, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException;
-
- // End of methods to download remote files from the server
-
-
- // Beginning of methods to upload local files to the server
-
- /**
- * 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.
- * Two exceptions: if the local file is binary, encoding does not apply.
- * If the local file is a XML file, then it will be copied to remote in the encoding
- * specified in the XML declaration, or as determined from the XML specification.
- * @param source the absolute path of the local copy
- * @param destination remote file that represents the file on the server
- * @param monitor the progress monitor
- */
- public void upload(String source, IRemoteFile destination, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException;
-
+ public void download(IRemoteFile source, String destination, String encoding, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException;
/**
* Put the local copy of the remote file back to the remote location. The file
@@ -551,30 +431,6 @@ public interface IRemoteFileSubSystem extends ISubSystem {
* @param monitor the progress monitor
*/
public void upload(String source, IRemoteFile destination, String encoding, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException;
-
- /**
- * Put local data to a remote location. The local data is assumed to be in the encoding specified.
- * @param stream the input stream containing the local data.
- * @param totalBytes the total number of bytes in the stream, or -1 if unknown. If -1 is specified, then the progress monitor must be null
.
- * @param destination remote file that represents the file on the server.
- * @param encoding the encoding of the local data, or null
to specify binary.
- * @param monitor the progress monitor.
- * @throws RemoteFileSecurityException
- * @throws RemoteFileIOException
- */
- public void upload(InputStream stream, long totalBytes, 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 of the local operating system.
- * Two exceptions: if the local file is binary, encoding does not apply.
- * If the local file is a XML file, then it will be copied to remote in the encoding
- * specified in the XML declaration, or as determined from the XML specification.
- * @param source the absolute path of the local copy
- * @param destination remote file that represents the file on the server
- * @param monitor the progress monitor
- */
- public void upload(String source, String destination, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException;
/**
* Put the local copy of the remote file back to the remote location. The file
@@ -589,96 +445,6 @@ public interface IRemoteFileSubSystem extends ISubSystem {
*/
public void upload(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 local file
- * must be in UTF-8 encoding.
- * Two exceptions: if the local file is binary, encoding does not apply.
- * If the local file is a XML file, then it will be copied to remote in the encoding
- * specified in the XML declaration, or as determined from the XML specification.
- * @param source the absolute path of the local copy
- * @param destination remote file that represents the file on the server
- * @param monitor the progress monitor
- */
- public void uploadUTF8(String source, IRemoteFile 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.
- * Two exceptions: if the local file is binary, encoding does not apply.
- * If the local file is a XML file, then it will be copied to remote in the encoding
- * specified in the XML declaration, or as determined from the XML specification.
- * @param source the local copy
- * @param destination remote file that represents the file on the server
- * @param monitor the progress monitor
- */
- public void upload(File source, IRemoteFile 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 specified.
- * Two exceptions: if the local file is binary, encoding does not apply.
- * If the local file is a XML file, then it will be copied to remote in the encoding
- * specified in the XML declaration, or as determined from the XML specification.
- * @param source the local copy
- * @param destination remote file that represents the file on the server
- * @param encoding the encoding of the local copy
- * @param monitor the progress monitor
- */
- public void upload(File source, IRemoteFile destination, String encoding, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException;
-
-
- /**
- * Put the local copy of the remote file back to the remote location. The local file
- * must be in UTF-8 encoding.
- * Two exceptions: if the local file is binary, encoding does not apply.
- * If the local file is a XML file, then it will be copied to remote in the encoding
- * specified in the XML declaration, or as determined from the XML specification.
- * @param source the local copy
- * @param destination remote file that represents the file on the server
- * @param monitor the progress monitor
- */
- public void uploadUTF8(File source, IRemoteFile 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.
- * Two exceptions: if the local file is binary, encoding does not apply.
- * If the local file is a XML file, then it will be copied to remote in the encoding
- * specified in the XML declaration, or as determined from the XML specification.
- * @param source the local copy
- * @param destination remote file that represents the file on the server
- * @param monitor the progress monitor
- */
- public void upload(IFile source, IRemoteFile 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 specified
- * @param source the local copy
- * @param destination remote file that represents the file on the server
- * @param encoding the encoding of the local copy
- * @param monitor the progress monitor
- */
- public void upload(IFile source, IRemoteFile destination, String encoding, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException;
-
-
- /**
- * Put the local copy of the remote file back to the remote location. The local file
- * must be in UTF-8 encoding.
- * Two exceptions: if the local file is binary, encoding does not apply.
- * If the local file is a XML file, then it will be copied to remote in the encoding
- * specified in the XML declaration, or as determined from the XML specification.
- * @param source the local copy
- * @param destination remote file that represents the file on the server
- * @param monitor the progress monitor
- */
- public void uploadUTF8(IFile source, IRemoteFile destination, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException;
-
-
/**
* @generated This field/method will be replaced during code generation
* @return The value of the HomeFolder attribute
diff --git a/rse/plugins/org.eclipse.rse.subsystems.files.core/src/org/eclipse/rse/subsystems/files/core/subsystems/RemoteFileSubSystem.java b/rse/plugins/org.eclipse.rse.subsystems.files.core/src/org/eclipse/rse/subsystems/files/core/subsystems/RemoteFileSubSystem.java
index 58eced6eb96..e7d8c089d1e 100644
--- a/rse/plugins/org.eclipse.rse.subsystems.files.core/src/org/eclipse/rse/subsystems/files/core/subsystems/RemoteFileSubSystem.java
+++ b/rse/plugins/org.eclipse.rse.subsystems.files.core/src/org/eclipse/rse/subsystems/files/core/subsystems/RemoteFileSubSystem.java
@@ -21,7 +21,6 @@ package org.eclipse.rse.subsystems.files.core.subsystems;
import java.io.BufferedReader;
import java.io.DataInputStream;
-import java.io.File;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
@@ -35,7 +34,6 @@ import java.util.Iterator;
import java.util.List;
import java.util.Vector;
-import org.eclipse.core.resources.IFile;
import org.eclipse.core.runtime.IPath;
import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.core.runtime.OperationCanceledException;
@@ -60,11 +58,8 @@ import org.eclipse.rse.services.clientserver.FileTypeMatcher;
import org.eclipse.rse.services.clientserver.IClientServerConstants;
import org.eclipse.rse.services.clientserver.IMatcher;
import org.eclipse.rse.services.clientserver.NamePatternMatcher;
-import org.eclipse.rse.services.clientserver.SystemEncodingUtil;
import org.eclipse.rse.services.clientserver.messages.SystemMessage;
import org.eclipse.rse.services.clientserver.messages.SystemMessageException;
-import org.eclipse.rse.services.files.RemoteFileIOException;
-import org.eclipse.rse.services.files.RemoteFileSecurityException;
import org.eclipse.rse.services.search.IHostSearchResult;
import org.eclipse.rse.services.search.IHostSearchResultConfiguration;
import org.eclipse.rse.subsystems.files.core.model.RemoteFileFilterString;
@@ -1196,261 +1191,6 @@ public abstract class RemoteFileSubSystem extends SubSystem implements IRemoteFi
return match;
}
- /**
- * Copy a file or folder to a new target parent folder.
- *
- * @param sourceFolderOrFile The file or folder to copy
- * @param targetFolder The folder to copy to. No guarantee it is on the same system, so be sure to check getSystemConnection()!
- * @param newName The new name for the copied file or folder
- * @return false true iff the copy succeeded
- */
-// public boolean copy(IRemoteFile sourceFolderOrFile, IRemoteFile targetFolder, String newName, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException
-// {
-// return false;
-// }
-
-
-
- /**
- * Get the remote file and save it locally. The file is saved in the encoding
- * of the operating system.
- * @param source remote file that represents the file to be obtained
- * @param destination the absolute path of the local file
- * @param monitor the progress monitor
- */
- public void download(IRemoteFile source, String destination, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException
- {
- download(source, destination, System.getProperty("file.encoding"), monitor); //$NON-NLS-1$
- }
-
- /**
- * Get the remote file and save it locally. The file is saved in the encoding
- * specified.
- * @param source remote file that represents the file to be obtained
- * @param destination the absolute path of the local file
- * @param encoding the encoding of the local file
- * @param monitor the progress monitor
- */
-// public void copy(IRemoteFile source, String destination, String encoding, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException
-// {
-// return;
-// }
-
- /**
- * Get the remote file and save it locally. The file is saved in UTF-8 encoding.
- * This is a recommended method to use for file transfer
- * @param source remote file that represents the file to be obtained
- * @param destination the absolute path of the local file
- * @param monitor the progress monitor
- */
- public void downloadUTF8(IRemoteFile source, String destination, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException
- {
- download(source, destination, SystemEncodingUtil.ENCODING_UTF_8, monitor);
- }
-
- /**
- * Get the remote file and save it locally. The file is saved in the encoding
- * of the operating system.
- * @param source remote file that represents the file to be obtained
- * @param destination the local file
- * @param monitor the progress monitor
- */
- public void download(IRemoteFile source, File destination, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException
- {
- download(source, destination.getAbsolutePath(), monitor);
- }
-
- /**
- * Get the remote file and save it locally. The file is saved in the encoding
- * specified.
- * @param source remote file that represents the file to be obtained
- * @param destination the local file
- * @param encoding the encoding of the local file
- * @param monitor the progress monitor
- */
- public void download(IRemoteFile source, File destination, String encoding, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException
- {
- download(source, destination.getAbsolutePath(), encoding, monitor);
- }
-
- /**
- * Get the remote file and save it locally. The file is saved in UTF-8 encoding.
- * This is a recommended method to use for file transfer
- * @param source remote file that represents the file to be obtained
- * @param destination the local file
- * @param monitor the progress monitor
- */
- public void downloadUTF8(IRemoteFile source, File destination, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException
- {
- downloadUTF8(source, destination.getAbsolutePath(), monitor);
- }
-
- /**
- * Get the remote file and save it locally. The file is saved in the encoding
- * of the operating system.
- * @param source remote file that represents the file to be obtained
- * @param destination the local file
- * @param monitor the progress monitor
- */
- public void download(IRemoteFile source, IFile destination, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException
- {
- download(source, destination.getLocation().makeAbsolute().toOSString(), monitor);
- }
-
- /**
- * Get the remote file and save it locally. The file is saved in the encoding
- * specified.
- * @param source remote file that represents the file to be obtained
- * @param destination the local file
- * @param encoding the encoding of the local file
- * @param monitor the progress monitor
- */
- public void download(IRemoteFile source, IFile destination, String encoding, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException
- {
- download(source, destination.getLocation().makeAbsolute().toOSString(), encoding, monitor);
- }
-
- /**
- * Get the remote file and save it locally. The file is saved in UTF-8 encoding.
- * This is a recommended method to use for file transfer
- * @param source remote file that represents the file to be obtained
- * @param destination the local file
- * @param monitor the progress monitor
- */
- public void downloadUTF8(IRemoteFile source, IFile destination, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException
- {
- downloadUTF8(source, destination.getLocation().makeAbsolute().toOSString(), monitor);
- }
-
- /**
- * 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
- * @param source the absolute path of the local copy
- * @param destination remote file that represents the file on the server
- * @param monitor the progress monitor
- */
- public void upload(String source, IRemoteFile destination, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException
- {
- upload(source, destination, System.getProperty("file.encoding"), monitor); //$NON-NLS-1$
- destination.markStale(true);
- }
-
- /**
- * Put the local copy of the remote file back to the remote location. The file
- * is assumed to be in the encoding specified
- * @param source the absolute path of the local copy
- * @param destination remote file that represents the file on the server
- * @param encoding the encoding of the local copy
- * @param monitor the progress monitor
- */
-
-// public void copy(String source, IRemoteFile destination, String encoding, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException
-// {
-// return;
-// }
-
- /**
- * 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
- * @param source the absolute path of the local copy
- * @param destination remote file that represents the file on the server
- * @param monitor the progress monitor
- */
- public void upload(String source, String destination, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException
- {
- upload(source, SystemEncodingUtil.ENCODING_UTF_8, destination, System.getProperty("file.encoding"), monitor); //$NON-NLS-1$
- }
-
- /**
- * Put the local copy of the remote file back to the remote location. The local file
- * must be in UTF-8 encoding.
- * @param source the absolute path of the local copy
- * @param destination remote file that represents the file on the server
- * @param monitor the progress monitor
- */
- public void uploadUTF8(String source, IRemoteFile destination, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException
- {
- upload(source, destination, SystemEncodingUtil.ENCODING_UTF_8, monitor);
- destination.markStale(true);
- }
-
- /**
- * 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
- * @param source the local copy
- * @param destination remote file that represents the file on the server
- * @param monitor the progress monitor
- */
- public void upload(File source, IRemoteFile destination, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException
- {
- upload(source.getAbsolutePath(), destination, monitor);
- }
-
- /**
- * Put the local copy of the remote file back to the remote location. The file
- * is assumed to be in the encoding specified
- * @param source the local copy
- * @param destination remote file that represents the file on the server
- * @param encoding the encoding of the local copy
- * @param monitor the progress monitor
- */
- public void upload(File source, IRemoteFile destination, String encoding, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException
- {
- upload(source.getAbsolutePath(), destination, encoding, monitor);
- destination.markStale(true);
- }
-
- /**
- * Put the local copy of the remote file back to the remote location. The local file
- * must be in UTF-8 encoding.
- * @param source the local copy
- * @param destination remote file that represents the file on the server
- * @param monitor the progress monitor
- */
- public void uploadUTF8(File source, IRemoteFile destination, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException
- {
- uploadUTF8(source.getAbsolutePath(), destination, monitor);
- }
-
- /**
- * 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
- * @param source the local copy
- * @param destination remote file that represents the file on the server
- * @param monitor the progress monitor
- */
- public void upload(IFile source, IRemoteFile destination, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException
- {
- upload(source.getLocation().makeAbsolute().toOSString(), destination, monitor);
- }
-
- /**
- * Put the local copy of the remote file back to the remote location. The file
- * is assumed to be in the encoding specified
- * @param source the local copy
- * @param destination remote file that represents the file on the server
- * @param encoding the encoding of the local copy
- * @param monitor the progress monitor
- */
- public void upload(IFile source, IRemoteFile destination, String encoding, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException
- {
- upload(source.getLocation().makeAbsolute().toOSString(), destination, encoding, monitor);
- }
-
- /**
- * Put the local copy of the remote file back to the remote location. The local file
- * must be in UTF-8 encoding.
- * @param source the local copy
- * @param destination remote file that represents the file on the server
- * @param monitor the progress monitor
- */
- public void uploadUTF8(IFile source, IRemoteFile destination, IProgressMonitor monitor) throws RemoteFileSecurityException, RemoteFileIOException
- {
- uploadUTF8(source.getLocation().makeAbsolute().toOSString(), destination, monitor);
- }
-
-
-
/**
* helper method to run an external command
*/