[#BloombergLP-bdlat_ArrayFunctions]
= xref:BloombergLP.adoc[BloombergLP]::bdlat&lowbar;ArrayFunctions
:relfileprefix: ../
:mrdocs:

This `namespace` provides functions that expose &quot;array&quot; behavior for &quot;array&quot; types&period; Specializations are provided for `bsl&colon;&colon;vector&lt;TYPE&gt;`&period; See the component&hyphen;level documentation for more information&period;

== Types

[cols="1,4"]
|===
| Name| Description
| xref:BloombergLP/bdlat_ArrayFunctions/ElementType-0d.adoc[`ElementType`] 
| This meta&hyphen;function should contain a typedef `Type` that specifies the type of element stored in an array of the parameterized `TYPE`&period;
| xref:BloombergLP/bdlat_ArrayFunctions/IsArray-09.adoc[`IsArray`] 
| This `struct` should be specialized for third&hyphen;party types that are need to expose &quot;array&quot; behavior&period; See the component&hyphen;level documentation for further information&period;
|===


== Functions

[cols="1,4"]
|===
| Name| Description
| xref:BloombergLP/bdlat_ArrayFunctions/accessElement.adoc[`accessElement`] 
| Invoke the specified `accessor` on the non&hyphen;modifiable element at the specified `index` of the specified `array`&period; The supplied `accessor` must be a callable type that can be called as if it had the following signature&colon; &grave; int accessor(const ELEMENT&lowbar;TYPE&amp; element)&semi; &grave; Return the value from the invocation of `accessor`&period; The behavior is undefined unless `0 &lt;&equals; index` and `index &lt; size(array)`&period;
| xref:BloombergLP/bdlat_ArrayFunctions/bdlat_arrayAccessElement.adoc[`bdlat&lowbar;arrayAccessElement`] 
| Invoke the specified `accessor` on the element at the specified `index` of the specified `array`&period; Return the value from the invocation of `accessor`&period;
| xref:BloombergLP/bdlat_ArrayFunctions/bdlat_arrayManipulateElement.adoc[`bdlat&lowbar;arrayManipulateElement`] 
| Apply the specified `manipulator` to the element at the specified `index` in the specified `array`&period;
| xref:BloombergLP/bdlat_ArrayFunctions/bdlat_arrayReserve-02.adoc[`bdlat&lowbar;arrayReserve`] 
| Reserve capacity for the specified `array` to hold at least the specified `numElements` elements&period;
| xref:BloombergLP/bdlat_ArrayFunctions/bdlat_arrayResize.adoc[`bdlat&lowbar;arrayResize`] 
| Resize the specified `array` to contain the specified `newSize` elements&period;
| xref:BloombergLP/bdlat_ArrayFunctions/bdlat_arraySize.adoc[`bdlat&lowbar;arraySize`] 
| Return the number of elements in the specified `array`&period;
| xref:BloombergLP/bdlat_ArrayFunctions/bdlat_arraySupportsReserve-07.adoc[`bdlat&lowbar;arraySupportsReserve`] 
| `bdlat&lowbar;arraySupportsReserve` overloads
| xref:BloombergLP/bdlat_ArrayFunctions/manipulateElement.adoc[`manipulateElement`] 
| &grave; Return the value from the invocation of `manipulator`&period; The behavior is undefined unless `0 &lt;&equals; index` and `index &lt; size(&ast;array)`&period;
| xref:BloombergLP/bdlat_ArrayFunctions/reserve.adoc[`reserve`] 
| If successful, make the capacity of the specified modifiable `array` at least the specified `numElements` and return zero&period; If unsuccessful or unsupported, return a non&hyphen;zero value&period; This method has no effect, and returns zero, if the current capacity meets or exceeds the required capacity&period; The behavior is undefined unless `0 &lt;&equals; numElements`&period;
| xref:BloombergLP/bdlat_ArrayFunctions/resize.adoc[`resize`] 
| Set the size of the specified modifiable `array` to the specified `newSize`&period; If `newSize &gt; size(array)`, then `newSize &hyphen; size(array)` elements with default values are appended to `array`&period; If `newSize &lt; size(array)`, then the `size(array) &hyphen; newSize` elements at the end of `array` are destroyed&period; The behavior is undefined unless `0 &lt;&equals; newSize`&period;
| xref:BloombergLP/bdlat_ArrayFunctions/size.adoc[`size`] 
| Return the number of elements in the specified `array`&period;
| xref:BloombergLP/bdlat_ArrayFunctions/supportsReserve.adoc[`supportsReserve`] 
| Return `true` if `reserve` will attempt to reserve capacity in the specified `array`, and `false` otherwise&period;
|===



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