boost::from_block_range
Reads blocks from the iterator range into the bitset.
Synopsis
Declared in <boost/dynamic_bitset/dynamic_bitset.hpp>
template<
typename BlockIterator,
typename Block,
typename AllocatorOrContainer>
void
from_block_range(
BlockIterator first,
BlockIterator last,
dynamic_bitset<Block, AllocatorOrContainer>& result);
Description
Each element of the range is converted to Block, and makes a whole block, as with the constructor from a range of blocks.
Throws
Any exception thrown by an operation of BlockIterator. In that case, result keeps its size, but some of its blocks may have been overwritten.
Parameters
Name |
Description |
first |
The start of the range. |
last |
The end of the range. |
result |
The resulting bitset. |
Preconditions
-
The type
BlockIteratormust be a model of LegacyInputIterator and itsvalue_typemust be implicitly convertible toBlockand be neitherboolnor a floating‐point type (astatic_assertchecks this). The size of the iterator range must be less than or equal tob.num_blocks(). Excess bits are not copied into the bitset, which doesn't change its size.
Created with MrDocs