Return an IndexSpan shrunk from the ends of the specified original.
Synopsis
Declared in <bdlb_indexspanutil.h>
static
IndexSpan
shrink(
IndexSpan const& original,
IndexSpan::size_type shrinkBegin,
IndexSpan::size_type shrinkEnd);
Description
The result is transformed using the specified shrinkBegin and shrinkEnd so that its position is original.position() + shrinkBegin and whose length is original.length() ‐ (shrinkBegin + shrinkEnd). The behavior is undefined unless shrinkBegin + shrinkEnd <= original.length().
Return Value
an IndexSpan shrunk from the ends of original
Parameters
Name |
Description |
original |
span to shrink |
shrinkBegin |
number of elements to remove from the start |
shrinkEnd |
number of elements to remove from the end |
Created with MrDocs