2014-01-14 14:22:06 +00:00
|
|
|
generic
|
2014-01-15 09:21:26 +00:00
|
|
|
type Utf8_Character_Type is (<>);
|
2014-01-14 14:22:06 +00:00
|
|
|
type Unicode_Character_Type is (<>);
|
2014-01-15 09:21:26 +00:00
|
|
|
package H2.Utf8 is
|
2014-01-14 14:22:06 +00:00
|
|
|
|
|
|
|
Invalid_Unicode_Character: exception;
|
|
|
|
|
|
|
|
subtype Unicode_Character is Unicode_Character_Type;
|
2014-01-15 09:21:26 +00:00
|
|
|
subtype Utf8_Character is Utf8_Character_Type;
|
2014-01-14 14:22:06 +00:00
|
|
|
|
2014-01-15 09:21:26 +00:00
|
|
|
type Utf8_String is array(System_Index range<>) of Utf8_Character;
|
2014-01-14 14:22:06 +00:00
|
|
|
type Unicode_String is array(System_Index range<>) of Unicode_Character;
|
|
|
|
|
2014-01-15 09:21:26 +00:00
|
|
|
function Unicode_To_Utf8 (UC: in Unicode_Character) return Utf8_String;
|
|
|
|
function Unicode_To_Utf8 (US: in Unicode_String) return Utf8_String;
|
2014-01-14 14:22:06 +00:00
|
|
|
|
2014-01-15 09:21:26 +00:00
|
|
|
--procedure Utf8_To_Unicode (Utf8: in Utf8_String;
|
2014-01-14 14:22:06 +00:00
|
|
|
-- UC: out Unicode_Character_Type);
|
|
|
|
|
2014-01-15 09:21:26 +00:00
|
|
|
end H2.Utf8;
|