Boost.AFIO    Boost C++ Libraries
Functions
Resizing files

Functions

virtual std::vector< future<> > boost::afio::dispatcher::truncate (const std::vector< future<>> &ops, const std::vector< off_t > &sizes)=0
 Schedule a batch of asynchronous file length truncations after preceding operations.
future boost::afio::async_truncate (future<> _precondition, off_t newsize)
 Asynchronous file length truncation after a preceding operation.
void boost::afio::truncate (future<> _precondition, off_t newsize)
 Synchronous file length truncation after a preceding operation.
void boost::afio::truncate (error_code &_ec, future<> _precondition, off_t newsize)
 Synchronous file length truncation after a preceding operation.

Function Documentation

future boost::afio::dispatcher::truncate ( const std::vector< future<>> &  ops,
const std::vector< off_t > &  sizes 
) [pure virtual]

Schedule a batch of asynchronous file length truncations after preceding operations.

Returns:
A batch of op handles.
Parameters:
opsA batch of op handles.
sizesA batch of new lengths.

Definition at line 3706 of file afio.hpp.

future boost::afio::async_truncate ( future<>  _precondition,
off_t  newsize 
)

Asynchronous file length truncation after a preceding operation.

Returns:
A future<void>
Parameters:
_preconditionThe precondition to use.
newsizeThe new size for the file.

{Amortised O(1) to dispatch. Amortised O(1) to complete if truncating file lengths is constant time.} {readwrite_example}

Definition at line 5270 of file afio.hpp.

void boost::afio::truncate ( future<>  _precondition,
off_t  newsize 
)

Synchronous file length truncation after a preceding operation.

Parameters:
_preconditionThe precondition to use.
newsizeThe new size for the file.

{distinguish, throwing} {Amortised O(1) to dispatch. Amortised O(1) to complete if truncating file lengths is constant time.} {readwrite_example}

Definition at line 5286 of file afio.hpp.

void boost::afio::truncate ( error_code &  _ec,
future<>  _precondition,
off_t  newsize 
)

Synchronous file length truncation after a preceding operation.

Parameters:
_ecError code to set.
_preconditionThe precondition to use.
newsizeThe new size for the file.

{distinguish, non throwing} {Amortised O(1) to dispatch. Amortised O(1) to complete if truncating file lengths is constant time.} {readwrite_example}

Definition at line 5303 of file afio.hpp.


January, 2014

Copyright © 2013-2014 Niall Douglas, Cork, Ireland
Copyright © 2013 Paul Kirth, California
Documentation is generated by Doxygen