```java
Buffer buffer = new Buffer().writeBytes(buffer, post, count);
ByteString result = buffer.readByteString(count);
```