Skip to main content

%IO.I.TranslationDevice

Class %IO.I.TranslationDevice Extends %IO.IParts.CharacterIO [ Abstract, System = 2 ]

This class is intended as a secondary superclass for those Stream classes that are implemented using InterSystems IRIS devices and thus support the use of a Translation Table for character set conversion on input, on output, or both. It contains a property TranslationTable that names the translation table to be used, if any. It also implements a number of classmethods to support the use of a Translation Table. This class also extends the class ILineStream which facilitates line-by-line Read and Write operations.

Properties

TranslationTable

Property TranslationTable As %String;

The name of the TranslationTable in effect for the Stream's device.

IsSingleByte

Property IsSingleByte As %Boolean;

Does the TranslationTable currently in effect represent a single-byte encoding.

Methods

SetCharEncodingTable

Method SetCharEncodingTable(pCharEncoding As %String, pCharEncodingAlias As %String) As %Status

Set translation table based on character encoding

TranslationTableSet

Method TranslationTableSet(pTable As %String) As %Status [ CodeMode = expression ]

SetTranslationTable

Method SetTranslationTable(pTable As %String) As %Status

IsTableSingleByte

ClassMethod IsTableSingleByte(pTable As %String) As %String [ CodeMode = expression ]

GetCharEncodingTable

ClassMethod GetCharEncodingTable(pCharEncoding As %String) As %String

GetLocaleDefaultTable

ClassMethod GetLocaleDefaultTable() As %String [ CodeMode = expression ]

IsLocaleUnicode

ClassMethod IsLocaleUnicode() As %Boolean [ CodeMode = expression ]

GetTableCharEncoding

ClassMethod GetTableCharEncoding(pTable As %String) As %String

GetDeviceTranslationTable

ClassMethod GetDeviceTranslationTable(pDevice As %String) As %String

SetDeviceTranslationTable

ClassMethod SetDeviceTranslationTable(pDevice As %String, pTable As %String, Output pSC As %Status) As %String

GetDeviceLineTerminator

ClassMethod GetDeviceLineTerminator(pDevice As %String) As %String

SetDeviceLineTerminator

ClassMethod SetDeviceLineTerminator(pDevice As %String, pLineTerm As %String, Output pSC As %Status)