Claims
- 1. A method for converting a multi-byte dataword in a first extended interchange code to a multi-byte dataword in a second extended interchange code, said method comprising the steps of:
- providing a plurality of offset arrays and a conversion matrix, wherein each entry in each of said plurality of offset arrays contains an offset index for indexing to said conversion matrix, wherein in each offset array, a difference between offset indices in each pair of adjacent entries is greater than one;
- returning an index value for each byte of said multi-byte dataword in said first extended interchange code from a corresponding one of said plurality of offset arrays; and
- adding all of said returned index values to obtain said multi-byte dataword in said second extended interchange code from said conversion matrix.
- 2. The method according to claim 1, wherein said method further includes a step of verifying each byte of said multi-byte dataword in said first extended interchange code is within the range of said corresponding one of said plurality of offset arrays.
- 3. The method according to claim 2, wherein said method further includes a step of indicating said multi-byte dataword is invalid, in response to any byte of said multi-byte dataword in said first extended interchange code falling outside the range of said corresponding one of said plurality of offset arrays.
- 4. The method according to claim 1, wherein said step of providing a plurality of offset arrays further includes a step of providing a first offset array having offset indices to each column of said conversion matrix and a second offset array having offset indices to each row of said conversion matrix.
- 5. The method according to claim 1, wherein said multi-byte dataword corresponds to a character of a written national language.
- 6. A computer system for converting a multi-byte dataword in a first extended interchange code to a multi-byte dataword in a second extended interchange code, comprising:
- means for providing a plurality of offset arrays and a conversion matrix, wherein each entry in each of said plurality of offset arrays contains an offset index for indexing to said conversion matrix, wherein in each offset array, a difference between offset indices in each pair of adjacent entries is greater than one;
- means for returning an index value for each byte of said multi-byte dataword in said first extended interchange code from a corresponding one of said plurality of offset arrays; and
- means for adding all of said returned index values to obtain said multi-byte dataword in said second extended interchange code from said conversion matrix.
- 7. The computer system according to claim 6, wherein said computer system further includes a means for verifying each byte of said multi-byte dataword in said first extended interchange code is within the range of said corresponding one of said plurality of offset arrays.
- 8. The computer system according to claim 7, wherein said computer system further includes a means for indicating said multi-byte dataword is invalid, in response to any byte of said multi-byte dataword in said first extended interchange code falling outside the range of said corresponding one of said plurality of offset arrays.
- 9. The computer system according to claim 6, wherein said means for providing a plurality of offset arrays further includes a means for providing a first offset array having offset indices to each column of said conversion matrix and a second offset array having offset indices to each row of said conversion matrix.
- 10. The computer system according to claim 6, wherein said multi-byte dataword corresponds to a character of a written national language.
- 11. A computer program product residing on a computer-usable medium for converting a multi-byte dataword in a first extended interchange code to a multi-byte dataword in a second extended interchange code within a computer system, said computer program product comprising:
- program code means for providing a plurality of offset arrays and a conversion matrix, wherein each entry in each of said plurality of offset arrays contains an offset index for indexing to said conversion matrix, wherein in each offset array, a difference between offset indices in each pair of adjacent entries is greater than one;
- program code means for returning an index value for each byte of said multi-byte dataword in said first extended interchange code from a corresponding one of said plurality of offset arrays; and
- program code means for adding all of said returned index values to obtain said multi-byte dataword in said second extended interchange code from said conversion matrix.
- 12. The computer program product according to claim 11, wherein said computer program product further includes a program code means for verifying each byte of said multi-byte dataword in said first extended interchange code is within the range of said corresponding one of said plurality of offset arrays.
- 13. The computer program product according to claim 12, wherein said computer program product further includes a program code means for indicating said multi-byte dataword is invalid, in response to any byte of said multi-byte dataword in said first extended interchange code falling outside the range of said corresponding one of said plurality of offset arrays.
- 14. The computer program product according to claim 11, wherein said program code means for providing a plurality of offset arrays further includes a program code means for providing a first offset array having offset indices to each column of said conversion matrix and a second offset array having offset indices to each row of said conversion matrix.
- 15. The computer program product according to claim 11, wherein said multi-byte dataword corresponds to a character of a written national language.
CROSS-REFERENCE TO A RELATED PATENT
The present invention is related to the subject matter of a U.S. Pat. No. 5,309,358, entitled "Method for Interchange Code Conversion of Multi-Byte Character String Characters," and assigned to the assignee herein named. The content of the above-mentioned United States Patent Application is incorporated by reference herein.
US Referenced Citations (5)