filebuf::sync | virtual protected member function |
int sync ( ); |
Synchronize file buffer
Synchronizes the internal character sequences with the file content.
This effectively means that if the internal output sequence (which in this class acts as a memory buffer for buffered streams) contains characters that have not yet been written to the file, these are now written by calling virtual member overflow.
The public member function pubsync of the parent class streambuf calls this virtual member function, which overrides the virtual member streambuf::sync.
Parameters
noneReturn Value
In case of success, zero is returned.Errors are expected to be signaled by any other value, like -1.
Basic template member declaration
( basic_filebuf<charT,traits> )
int sync ( );
|
See also
streambuf::pubsync | Synchronize stream buffer (public member function) |