public override int GetCharCount (byte[] bytes, int index, int count)
{
if (bytes == null) {
throw new ArgumentNullException ("bytes");
}
if (index < 0 || index > bytes.Length) {
throw new ArgumentOutOfRangeException ("index", _("ArgRange_Array"));
}
if (count < 0 || count > (bytes.Length - index)) {
throw new ArgumentOutOfRangeException ("count", _("ArgRange_Array"));
}
if (leftOverByte != -1) {
return (count + 1) / 2;
} else {
return count / 2;
}
}