public override unsafe int GetChars(byte *bytes, int byteCount,
char *chars, int charCount, bool flush)
{
if (bytes is null)
{
throw new ArgumentNullException(nameof(bytes));
}
if (chars is null)
{
throw new ArgumentNullException(nameof(chars));
}
if (byteCount < 0 || charCount < 0)
{
throw new ArgumentOutOfRangeException((byteCount < 0 ? nameof(byteCount) : nameof(charCount)), SR.ArgumentOutOfRange_NeedNonNegNum);
}
// Remember our flush
m_mustFlush = flush;
m_throwOnOverflow = true;
// By default just call the encoding's version
return(m_encoding.GetChars(bytes, byteCount, chars, charCount, this));
}