[#BloombergLP-bdlb-IndexSpanUtil-shrink]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bdlb.adoc[bdlb]::xref:BloombergLP/bdlb/IndexSpanUtil.adoc[IndexSpanUtil]::shrink
:relfileprefix: ../../../
:mrdocs:

Return an `IndexSpan` object transformed from the specified `original` using the specified `shrinkBegin` and `shrinkEnd` so that its position is `original&period;position() &plus; shrinkBegin` and whose length is `original&period;length() &hyphen; (shrinkBegin &plus; shrinkEnd)`&period; The behavior is undefined unless `shrinkBegin &plus; shrinkEnd &lt;&equals; original&period;length()`&period;

== Synopsis

Declared in `&lt;bdlb&lowbar;indexspanutil&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
static
xref:BloombergLP/bdlb/IndexSpan.adoc[IndexSpan]
shrink(
    xref:BloombergLP/bdlb/IndexSpan.adoc[IndexSpan] const& original,
    xref:BloombergLP/bdlb/IndexSpan/size_type.adoc[IndexSpan::size&lowbar;type] shrinkBegin,
    xref:BloombergLP/bdlb/IndexSpan/size_type.adoc[IndexSpan::size&lowbar;type] shrinkEnd);
----


[.small]#Created with https://www.mrdocs.com[MrDocs]#
