b832b14db0
* a-assert.ads: Remove execute permission. * a-chacon.ads: Likewise. * a-coteio.ads: Likewise. * a-envvar.ads: Likewise. * a-exetim-mingw.ads: Likewise. * a-fzteio.ads: Likewise. * a-izteio.ads: Likewise. * a-lcteio.ads: Likewise. * a-llctio.ads: Likewise. * a-scteio.ads: Likewise. * a-suenco.ads: Likewise. * a-suenst.ads: Likewise. * a-suewst.ads: Likewise. * a-suezst.ads: Likewise. * a-tirsfi.ads: Likewise. * a-wichha.ads: Likewise. * a-zchara.ads: Likewise. * a-zchhan.ads: Likewise. * a-zchuni.ads: Likewise. * a-zrstfi.ads: Likewise. * aspects.ads: Likewise. * g-byorma.ads: Likewise. * g-decstr.ads: Likewise. * g-encstr.ads: Likewise. * g-spchge.ads: Likewise. * g-u3spch.ads: Likewise. * g-wispch.ads: Likewise. * g-zspche.ads: Likewise. * namet-sp.ads: Likewise. * s-os_lib.ads: Likewise. * s-regexp.ads: Likewise. * s-regpat.ads: Likewise. * s-string.ads: Likewise. * s-tasloc.ads: Likewise. * s-utf_32.ads: Likewise. * sem_aux.ads: Likewise. * a-assert.adb: Likewise. * a-chacon.adb: Likewise. * a-envvar.adb: Likewise. * a-exetim-mingw.adb: Likewise. * a-suenco.adb: Likewise. * a-suenst.adb: Likewise. * a-suewst.adb: Likewise. * a-suezst.adb: Likewise. * a-tirsfi.adb: Likewise. * a-wichha.adb: Likewise. * a-zchhan.adb: Likewise. * a-zchuni.adb: Likewise. * a-zrstfi.adb: Likewise. * aspects.adb: Likewise. * g-byorma.adb: Likewise. * g-decstr.adb: Likewise. * g-encstr.adb: Likewise. * g-spchge.adb: Likewise. * g-u3spch.adb: Likewise. * g-wispch.adb: Likewise. * g-zspche.adb: Likewise. * namet-sp.adb: Likewise. * s-except.adb: Likewise. * s-inmaop-vxworks.adb: Likewise. * s-os_lib.adb: Likewise. * s-regexp.adb: Likewise. * s-regpat.adb: Likewise. * s-string.adb: Likewise. * s-tasloc.adb: Likewise. * s-utf_32.adb: Likewise. * s-wchcon.adb: Likewise. * sem_aux.adb: Likewise. From-SVN: r186261
62 lines
3.0 KiB
Ada
62 lines
3.0 KiB
Ada
------------------------------------------------------------------------------
|
|
-- --
|
|
-- GNAT RUN-TIME COMPONENTS --
|
|
-- --
|
|
-- ADA.STRINGS.UTF_ENCODING.CONVERSIONS --
|
|
-- --
|
|
-- S p e c --
|
|
-- --
|
|
-- This specification is derived from the Ada Reference Manual for use with --
|
|
-- GNAT. In accordance with the copyright of that document, you can freely --
|
|
-- copy and modify this specification, provided that if you redistribute a --
|
|
-- modified version, any changes that you have made are clearly indicated. --
|
|
-- --
|
|
------------------------------------------------------------------------------
|
|
|
|
-- This is an Ada 2012 package defined in AI05-0137-1. It provides conversions
|
|
-- from one UTF encoding method to another. Note: this package is consistent
|
|
-- with Ada 95, and may be used in Ada 95 or Ada 2005 mode.
|
|
|
|
package Ada.Strings.UTF_Encoding.Conversions is
|
|
pragma Pure (Conversions);
|
|
|
|
-- In the following conversion routines, a BOM in the input that matches
|
|
-- the encoding scheme is ignored, an incorrect BOM causes Encoding_Error
|
|
-- to be raised. A BOM is present in the output if the Output_BOM parameter
|
|
-- is set to True.
|
|
|
|
function Convert
|
|
(Item : UTF_String;
|
|
Input_Scheme : Encoding_Scheme;
|
|
Output_Scheme : Encoding_Scheme;
|
|
Output_BOM : Boolean := False) return UTF_String;
|
|
-- Convert from input encoded in UTF-8, UTF-16LE, or UTF-16BE as specified
|
|
-- by the Input_Scheme argument, and generate an output encoded in one of
|
|
-- these three schemes as specified by the Output_Scheme argument.
|
|
|
|
function Convert
|
|
(Item : UTF_String;
|
|
Input_Scheme : Encoding_Scheme;
|
|
Output_BOM : Boolean := False) return UTF_16_Wide_String;
|
|
-- Convert from input encoded in UTF-8, UTF-16LE, or UTF-16BE as specified
|
|
-- by the Input_Scheme argument, and generate an output encoded in UTF-16.
|
|
|
|
function Convert
|
|
(Item : UTF_8_String;
|
|
Output_BOM : Boolean := False) return UTF_16_Wide_String;
|
|
-- Convert from UTF-8 to UTF-16
|
|
|
|
function Convert
|
|
(Item : UTF_16_Wide_String;
|
|
Output_Scheme : Encoding_Scheme;
|
|
Output_BOM : Boolean := False) return UTF_String;
|
|
-- Convert from UTF-16 to UTF-8, UTF-16LE, or UTF-16BE as specified by
|
|
-- the Output_Scheme argument.
|
|
|
|
function Convert
|
|
(Item : UTF_16_Wide_String;
|
|
Output_BOM : Boolean := False) return UTF_8_String;
|
|
-- Convert from UTF-16 to UTF-8
|
|
|
|
end Ada.Strings.UTF_Encoding.Conversions;
|