UTF8Encoding

UTF8Encoding


A set of functions to be used to convert character arrays to and from byte arrays.


Remarks

UTF-8 is an encoding scheme that is fully compatible with the existing ASCII set of characters (0-127). It also supports Unicode characters, including the UTF-16 character set.

UTF-8 is useful because it will have a size ratio of 1:1 for pure ASCII characters. The ratio will increase during the encoding for characters outside ASCII.

Additional information about UTF-8 encoding scheme can be found at "http://www.faqs.org/rfcs/rfc2279.html".

See Also

Project VBCorLib Overview | Constructors | Encoding

Implements:

Encoding 
IObject 

Public:

Properties:

NameDescription
 BodyName (get)Returns the encoding name to be used in with the mail agent body tags. 
 CodePage (get)Returns the code page identifier for this encoding. 
 EncodingName (get)The name of this encoding. 
 HeaderName (get)Returns the encoding name to be used in with the mail agent header tags. 
 IsBrowserDisplay (get)Indicates if this encoding can be used by browsers to display text. 
 IsBrowserSave (get)Indicates if this encoding can be used to save data with this encoding. 
 IsMailNewsDisplay (get)Indicates if this encoding can be used to display mail and news by mail and news clients. 
 IsMailNewsSave (get)Indicates if this encoding can be used to save data by mail and news clients. 
 IsSingleByte (get)Returns if the current encoding uses single-byte code points. 
 WebName (get)Returns the encoding name registered with the Internet Assigned Numbers Authority. 
 WindowsCodePage (get)Returns the Windows Operating Systems code page for this encoding. 

Methods:

NameDescription
 EqualsReturns a boolean indicating if the value and this object instance are the same instance. 
 GetByteCountReturns the number of bytes that would be produced from the set of characters using this encoding. 
 GetBytesEncodes a set of characters into an array of bytes. 
 GetBytesExEncodes a set of characters into an array of bytes, returning the number of bytes produced. 
 GetCharCountReturns the number of characters that would be produced by decoding a byte array. 
 GetCharsDecodes a set of bytes into a set of characters. 
 GetCharsExDecodes a set of bytes into the supplied Integer array. 
 GetDecoderReturns a decoder that maintains state. 
 GetEncoderReturns an encoder that maintains state. 
 GetHashCodeReturns a pseudo-unique number identifying this instance. 
 GetMaxByteCountReturns the maximum number of bytes that can be created from a specific number of characters. 
 GetMaxCharCountReturns the maximum number of characters than can be decoded from the number of bytes specified. 
 GetPreambleReturns an array of bytes that represents this encoding. 
 GetStringDecodes a set of bytes into a String. 
 ToStringReturns a string representation of this object instance.