## ICUEncoder::GetByteCount(ArrayPtr\<char_t\>, int, int, bool) method


获取编码缓冲区所需的字节数。

```cpp
virtual int System::Text::ICUEncoder::GetByteCount(ArrayPtr<char_t> chars, int index, int count, bool flush)
```


| 参数 | 类型 | 描述 |
| --- | --- | --- |
| chars | ArrayPtr\<char_t\> | 要编码的字符。 |
| index | int | [Buffer](../../../system/buffer/) 偏移。 |
| count | int | 要编码的字符数。 |
| flush | bool | 如果为 true，则在计算后清除内部编码器状态。 |

### ReturnValue

对缓冲区进行编码所需的字节数。

## 另见

* Typedef [ArrayPtr](../../../system/arrayptr/)
* Class [ICUEncoder](../)
* Namespace [System::Text](../../)
* Library [Aspose.Font for C++](../../../)
## ICUEncoder::GetByteCount(const char_t *, int, bool) method


获取编码缓冲区所需的字节数。

```cpp
virtual int System::Text::ICUEncoder::GetByteCount(const char_t *chars, int count, bool flush)
```


| 参数 | 类型 | 描述 |
| --- | --- | --- |
| chars | const char_t * | 要编码的字符。 |
| count | int | 要编码的字符数。 |
| flush | bool | 如果为 true，则在计算后清除内部编码器状态。 |

### ReturnValue

对缓冲区进行编码所需的字节数。

## 另见

* Class [ICUEncoder](../)
* Namespace [System::Text](../../)
* Library [Aspose.Font for C++](../../../)
