Class BytesOutStream#

Inheritance Relationships#

Base Type#

Class Documentation#

class BytesOutStream : public tvm::support::Stream#

Write-only stream that appends to a caller-provided std::string.

Public Functions

inline explicit BytesOutStream(std::string *buffer)#
inline virtual size_t Write(const void *ptr, size_t size) override#

Write raw bytes to the stream.

Parameters:
  • ptr – Source buffer.

  • size – Number of bytes to write.

Returns:

Number of bytes actually written.

inline virtual size_t Read(void*, size_t) override#

Read raw bytes from the stream.

Parameters:
  • ptr – Destination buffer.

  • size – Number of bytes to read.

Returns:

Number of bytes actually read.