Home | History | Annotate | Download | only in public

Lines Matching refs:Encoding

8 // This interface defines the Encoding enum and various functions that
9 // depend only on Encoding values.
11 // A hash-function for Encoding, hash<Encoding>, is defined in
15 // Encoding enum below from compiling. Note that this is a quick fix that does
21 // NOTE: The Encoding enum must always start at 0. This assumption has
41 // some of the popular encoding aliases
42 // TODO(jrm) Make these static const Encoding values instead of macros.
55 // The default Encoding (LATIN1).
56 Encoding default_encoding();
61 // Encoding predicates
83 bool IsValidEncoding(Encoding enc);
90 // first encoding to the second requires any changes to the underlying
97 bool IsEncEncCompatible(const Encoding from, const Encoding to);
100 // encoding represent the same characters as they do in ISO_8859_1.
104 bool IsSupersetOfAscii7Bit(Encoding e);
106 // To be an 8-bit encoding means that there are fewer than 256 symbols.
111 bool Is8BitEncoding(Encoding e);
116 // This function returns true if the encoding is either Chinese
118 // considered a CJK encoding.
119 bool IsCJKEncoding(Encoding e);
124 // This function returns true if the encoding is a Hebrew specific
125 // encoding (not UTF8, etc).
126 bool IsHebrewEncoding(Encoding e);
131 // Returns true if the encoding is a right-to-left encoding.
141 bool IsRightToLeftEncoding(Encoding enc);
146 // Returns true if the encoding is a logical right-to-left encoding.
154 bool IsLogicalRightToLeftEncoding(Encoding enc);
159 // Returns true if the encoding is a visual right-to-left encoding.
163 // by abusing <br> or <p> tags, etc. Visual RTL encoding is a relic of
168 bool IsVisualRightToLeftEncoding(Encoding enc);
173 // Returns true if the encoding is a kind of ISO 2022 such as
175 bool IsIso2022Encoding(Encoding enc);
180 // Returns true if the encoding is ISO-2022-JP or a variant such as
182 bool IsIso2022JpOrVariant(Encoding enc);
187 // Returns true if the encoding is Shift_JIS or a variant such as
189 bool IsShiftJisOrVariant(Encoding enc);
194 // Returns true if it's Japanese cell phone carrier specific encoding
196 bool IsJapaneseCellPhoneCarrierSpecificEncoding(Encoding enc);
201 // ENCODING NAMES
203 // This interface defines a standard name for each valid encoding, and
207 // EncodingName() [Encoding to name]
208 // MimeEncodingName() [Encoding to name]
209 // EncodingFromName() [name to Encoding]
210 // EncodingNameAliasToEncoding() [name to Encoding]
218 // Given the encoding, returns its standard name.
219 // Return invalid_encoding_name() if the encoding is invalid.
221 const char* EncodingName(Encoding enc);
227 // Return the "preferred MIME name" of an encoding.
231 const char* MimeEncodingName(Encoding enc);
234 // The maximum length of an encoding name
237 // The standard name of the default encoding.
240 // The name used for an invalid encoding.
246 // If enc_name matches the standard name of an Encoding, using a
247 // case-insensitive comparison, set *encoding to that Encoding and
248 // return true. Otherwise set *encoding to UNKNOWN_ENCODING and
251 // REQUIRES: encoding must not be NULL.
253 bool EncodingFromName(const char* enc_name, Encoding *encoding);
259 // If enc_name matches the standard name or an alias of an Encoding,
261 // Encoding. Otherwise, return UNKNOWN_ENCODING.
263 // Aliases include most mime-encoding names (e.g., "ISO-8859-7" for
268 Encoding EncodingNameAliasToEncoding(const char *enc_name);
286 // encoding, if there is one, thereby preserving the client's intent
290 Encoding PreferredWebOutputEncoding(Encoding enc);