FileDocCategorySizeDatePackage
Conv.javaAPI DocphoneME MR2 API (J2ME)5096Wed May 02 18:00:02 BST 2007com.sun.cldc.i18n.j2me

Conv

public class Conv extends Object
Character conversion base class

Fields Summary
Constructors Summary
Methods Summary
static native intbyteToChar(int handler, byte[] input, int in_offset, int in_len, char[] output, int out_offset, int out_len)
Native function to convert an array of bytes to converted array of characters.

param
handler handle returned from getHandler
param
input buffer of bytes to be converted
param
in_offset offset into the provided buffer
param
in_len length of data to be processed
param
output buffer of converted bytes
param
out_offset offset into the provided output buffer
param
out_len length of data processed
return
length of the converted string, or zero if the arguments were not valid
see
#getHandler

static native intcharToByte(int handler, char[] input, int in_offset, int in_len, byte[] output, int out_offset, int out_len)
Native function to convert an array of characters to an array of converted characters.

param
handler handle returned from getHandler
param
input buffer of bytes to be converted
param
in_offset offset into the provided buffer
param
in_len length of data to be processed
param
output buffer of converted bytes
param
out_offset offset into the provided output buffer
param
out_len length of data processed
return
length of the converted string, or zero if the arguments were not valid
see
#getHandler

static native intgetByteLength(int handler, byte[] b, int offset, int len)
Get the length of a specific converted string.

param
handler handle returned from getHandler
param
b buffer of bytes to be converted
param
offset offset into the provided buffer
param
len length of data to be processed
return
length of the converted string, or zero if arguments were not valid
see
#getHandler

static native intgetHandler(java.lang.String encoding)
Native method to get a handle to specific character encoding conversion routine.

param
encoding character encoding
return
identifier for requested handler, or -1 if the encoding was not supported.

static native intgetMaxByteLength(int handler)
Native function to set the maximum length in bytes for a converted string.

param
handler handle returned from getHandler
return
maximum byte length, or zero if handler is not valid
see
#getHandler

static native intsizeOfByteInUnicode(int handler, byte[] b, int offset, int length)
Native function to get the length of a specific converted string as an array of Unicode bytes.

param
handler handle returned from getHandler
param
b buffer of bytes to be converted
param
offset offset into the provided buffer
param
length length of data to be processed
return
length of the converted string, or zero if the arguments were not valid
see
#getHandler

static native intsizeOfUnicodeInByte(int handler, char[] c, int offset, int length)
Native function to get the length of a specific converted string as an array of Unicode characters.

param
handler handle returned from getHandler
param
c buffer of characters to be converted
param
offset offset into the provided buffer
param
length length of data to be processed
return
length of the converted string, or zero if the arguments were not valid
see
#getHandler