|
 |
|
|
org.eclipse.rse.services.files
Class DefaultFileServiceCodePageConverter
java.lang.Object
org.eclipse.rse.services.files.DefaultFileServiceCodePageConverter
-
All Implemented Interfaces:
-
IFileServiceCodePageConverter
-
public class DefaultFileServiceCodePageConverter
- extends
Object
- implements
IFileServiceCodePageConverter
-
Since:
- 3.0
Method Summary
|
byte[]
|
convertClientStringToRemoteBytes
(
String remotePath,
String clientString,
String remoteEncoding,
IFileService fs)
Converts a client string to remote bytes, for use when uploading in binary mode. |
void
|
convertFileFromRemoteEncoding
(
String remotePath,
File file,
String remoteEncoding,
String localEncoding,
IFileService fs)
Converts the specified file (which was downloaded from the server in binary mode) from server encoding bytes, to local encoding |
int
|
getPriority
(
String remoteEString,
IFileService fs)
to make another converter take precedence over this, supply a
code page converter returning a lower number (i.e. higher priority) |
boolean
|
isServerEncodingSupported
(
String remoteEncoding,
IFileService fs)
Indicates whether or not the specified server encoding and subsystem implementation is supported by this code page converter |
Methods inherited from class java.lang.
Object
|
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait
|
DefaultFileServiceCodePageConverter
public DefaultFileServiceCodePageConverter()
convertClientStringToRemoteBytes
public byte[] convertClientStringToRemoteBytes(
String remotePath,
String clientString,
String remoteEncoding,
IFileService fs)
-
Description copied from interface:
IFileServiceCodePageConverter
- Converts a client string to remote bytes, for use when uploading in binary mode.
-
-
Specified by:
-
convertClientStringToRemoteBytes
in interface
IFileServiceCodePageConverter
-
-
Parameters:
-
remotePath - the path of the remote file -
clientString - the client string to convert -
remoteEncoding - The remote encoding for the desired server bytes -
fs - The file service to apply conversion to.
Can be used to determine implementation specific settings to the converter
-
Returns:
- The bytes to upload to the server
convertFileFromRemoteEncoding
public void convertFileFromRemoteEncoding(
String remotePath,
File file,
String remoteEncoding,
String localEncoding,
IFileService fs)
-
Description copied from interface:
IFileServiceCodePageConverter
- Converts the specified file (which was downloaded from the server in binary mode) from server encoding bytes, to local encoding
-
-
Specified by:
-
convertFileFromRemoteEncoding
in interface
IFileServiceCodePageConverter
-
-
Parameters:
-
remotePath - the path of the remote file -
file - The file to convert -
localEncoding - The remote encoding of the file -
fs - The file service to apply conversion to.
Can be used to determine implementation specific settings to the converter
isServerEncodingSupported
public boolean isServerEncodingSupported(
String remoteEncoding,
IFileService fs)
-
Description copied from interface:
IFileServiceCodePageConverter
- Indicates whether or not the specified server encoding and subsystem implementation is supported by this code page converter
-
-
Specified by:
-
isServerEncodingSupported
in interface
IFileServiceCodePageConverter
-
-
Parameters:
-
remoteEncoding - The remote encoding from the server to check -
fs - The file service to apply conversion to.
Can be used to determine implementation specific settings to the converter
-
Returns:
- True if this code page converter can convert the specified encoding, false otherwise
getPriority
public int getPriority(
String remoteEString,
IFileService fs)
- to make another converter take precedence over this, supply a
code page converter returning a lower number (i.e. higher priority)
-
-
Specified by:
-
getPriority
in interface
IFileServiceCodePageConverter
-
-
Returns:
- priority
Copyright (c) IBM Corporation and others 2000, 2008. All Rights Reserved.
|
|
|