XML 中的 Unicode 字符串 [英] Unicode string in XML
问题描述
在xml中unicode表示如下:
例如:
\ue349
如果我想写一个由两个字符组成的字符串,unicodes e343 e312 怎么办
如何用 XML 表示?
XML 不使用 \ue349
表示法.字符引用,以&#
, 可以使用,但大多不需要.XML 通常与 UTF-8 字符编码一起使用,这样每个字符都可以这样写.(在程序中生成 XML 时,如果编程语言支持,您可能会使用像 \ue349
这样的符号.)
在 Unicode 中,数字 E343 和 E312 指的是专用代码点,标准没有为其分配字符.它们可以根据需要由私人协议使用,但您不应期望任何软件或任何人理解它们,除非此类协议.考虑到这一点,代码点 U+E343 U+E312(以及它们可能通过某种协议表示的字符)可以写成 
.>
In xml unicode are represented as follows:
e.g:
\ue349
What if I want to write a string consists of two chars with unicodes e343 e312
How can this be represented in XML?
XML does not use \ue349
notation. Character references, starting with &#
, may be used, but they are mostly not needed. XML is usually used with UTF-8 character encoding, so that each character can be written as such. (When generating XML in a program, you might well use a notation like \ue349
if supported by the programming language.)
In Unicode, the numbers E343 and E312 refer to Private Use codepoints, to which no character is assigned by the standard. They may be used by private agreements as desired, but you should not expect any software or any person to understand them, except by such agreements. With this in mind, the code points U+E343 U+E312 (and hence the characters they may denote by some agreement) can be written as 
.
这篇关于XML 中的 Unicode 字符串的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!