Determines the exact number of characters that will be produced by decoding a specified range of bytes, when implemented in a subclass.
[Visual Basic] MustOverride Public Function GetCharCount( _ ByVal bytes() As Byte, _ ByVal index As Integer, _ ByVal count As Integer _ ) As Integer [C#] public abstract int GetCharCount( byte[] bytes, int index, int count ); [C++] public: virtual int GetCharCount( unsigned char* bytes[], int index, int count ) = 0; [JScript] public abstract function GetCharCount( bytes : Byte[], index : int, count : int ) : int;
The number of characters the next call to GetChars will produce if presented with the specified range of bytes. The returned value takes into account the state in which the decoder was left following the last call to GetChars.
Exception Type | Condition |
---|---|
ArgumentNullException | The bytes argument is null. |
ArgumentOutOfRangeException | The index and count arguments do not denote a valid range in the byte array. |
The state of the decoder is not affected by a call to this method.