MySQL  8.0.27
Source Code Documentation
Truncatable_ostream Class Referenceabstract

Truncatable_ostream abstract class provides seek() and truncate() interfaces to all truncatable output streams. More...

#include <basic_ostream.h>

Inheritance diagram for Truncatable_ostream:
Basic_ostream Binlog_encryption_ostream IO_CACHE_binlog_cache_storage IO_CACHE_ostream

Public Member Functions

virtual bool truncate (my_off_t offset)=0
 Truncate some data at the end of the output stream. More...
 
virtual bool seek (my_off_t offset)=0
 Put the write position to a given offset. More...
 
virtual bool flush ()=0
 Flush data. More...
 
virtual bool sync ()=0
 Sync. More...
 
 ~Truncatable_ostream () override=default
 
- Public Member Functions inherited from Basic_ostream
virtual bool write (const unsigned char *buffer, my_off_t length)=0
 Write some bytes into the output stream. More...
 
virtual ~Basic_ostream ()=default
 

Detailed Description

Truncatable_ostream abstract class provides seek() and truncate() interfaces to all truncatable output streams.

Constructor & Destructor Documentation

◆ ~Truncatable_ostream()

Truncatable_ostream::~Truncatable_ostream ( )
overridedefault

Member Function Documentation

◆ flush()

virtual bool Truncatable_ostream::flush ( )
pure virtual

Flush data.

Return values
falseSuccess.
trueError.

Implemented in Binlog_encryption_ostream, IO_CACHE_binlog_cache_storage, and IO_CACHE_ostream.

◆ seek()

virtual bool Truncatable_ostream::seek ( my_off_t  offset)
pure virtual

Put the write position to a given offset.

The offset counts from the beginning of the file.

Parameters
[in]offsetWhere the write position will be
Return values
falseSuccess
trueError

Implemented in Binlog_encryption_ostream, and IO_CACHE_ostream.

◆ sync()

virtual bool Truncatable_ostream::sync ( )
pure virtual

Sync.

Return values
falseSuccess
trueError

Implemented in Binlog_encryption_ostream, IO_CACHE_binlog_cache_storage, and IO_CACHE_ostream.

◆ truncate()

virtual bool Truncatable_ostream::truncate ( my_off_t  offset)
pure virtual

Truncate some data at the end of the output stream.

Parameters
[in]offsetWhere the output stream will be truncated to.
Return values
falseSuccess
trueError

Implemented in Binlog_encryption_ostream, IO_CACHE_binlog_cache_storage, and IO_CACHE_ostream.


The documentation for this class was generated from the following file: