Input stream from base64 encoding.
More...
#include <base64.h>
|
| | Base64InStream (tvm::support::Stream *fs) |
| |
| void | InitPosition (void) |
| | initialize the stream position to beginning of next base64 stream
|
| |
| bool | IsEOF (void) const |
| | whether current position is end of a base64 stream
|
| |
| size_t | Read (void *ptr, size_t size) final |
| | Read raw bytes from the stream.
|
| |
| size_t | Write (const void *ptr, size_t size) final |
| | Write raw bytes to the stream.
|
| |
| virtual | ~Stream ()=default |
| | Virtual destructor.
|
| |
| template<typename T > |
| void | Write (const T &data) |
| | Write a typed value using Serializer<T>.
|
| |
| template<typename T > |
| bool | Read (T *out_data) |
| | Read a typed value using Serializer<T>.
|
| |
| template<typename T > |
| void | WriteArray (const T *data, size_t num_elems) |
| | Write an array of typed values element by element.
|
| |
| template<typename T > |
| bool | ReadArray (T *data, size_t num_elems) |
| | Read an array of typed values element by element.
|
| |
Input stream from base64 encoding.
◆ Base64InStream()
◆ InitPosition()
| void tvm::support::Base64InStream::InitPosition |
( |
void |
| ) |
|
|
inline |
initialize the stream position to beginning of next base64 stream
- Note
- call this function before actually start read
◆ IsEOF()
| bool tvm::support::Base64InStream::IsEOF |
( |
void |
| ) |
const |
|
inline |
whether current position is end of a base64 stream
◆ Read()
| size_t tvm::support::Base64InStream::Read |
( |
void * |
ptr, |
|
|
size_t |
size |
|
) |
| |
|
inlinefinalvirtual |
Read raw bytes from the stream.
- Parameters
-
| ptr | Destination buffer. |
| size | Number of bytes to read. |
- Returns
- Number of bytes actually read.
Implements tvm::support::Stream.
◆ Write()
| size_t tvm::support::Base64InStream::Write |
( |
const void * |
ptr, |
|
|
size_t |
size |
|
) |
| |
|
inlinefinalvirtual |
Write raw bytes to the stream.
- Parameters
-
| ptr | Source buffer. |
| size | Number of bytes to write. |
- Returns
- Number of bytes actually written.
Implements tvm::support::Stream.
The documentation for this class was generated from the following file: