[#BloombergLP-bdlc-BitArray-2constructor-011] = xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bdlc.adoc[bdlc]::xref:BloombergLP/bdlc/BitArray.adoc[BitArray]::BitArray :relfileprefix: ../../../ :mrdocs: Constructors == Synopses Declared in `<bdlc_bitarray.h>` Create an empty array of binary digits (bits). [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- explicit xref:BloombergLP/bdlc/BitArray/2constructor-01f.adoc[BitArray](xref:BloombergLP/bslma/Allocator.adoc[bslma::Allocator]* basicAllocator = 0); ---- [.small]#xref:BloombergLP/bdlc/BitArray/2constructor-01f.adoc[_» more..._]# Create a bit array of the specified initial length. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- explicit xref:BloombergLP/bdlc/BitArray/2constructor-04.adoc[BitArray]( std::size_t initialLength, xref:BloombergLP/bslma/Allocator.adoc[bslma::Allocator]* basicAllocator = 0); ---- [.small]#xref:BloombergLP/bdlc/BitArray/2constructor-04.adoc[_» more..._]# Create a bit array having the same value as `original`. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- xref:BloombergLP/bdlc/BitArray/2constructor-00.adoc[BitArray]( xref:BloombergLP/bdlc/BitArray.adoc[BitArray] const& original, xref:BloombergLP/bslma/Allocator.adoc[bslma::Allocator]* basicAllocator = 0); ---- [.small]#xref:BloombergLP/bdlc/BitArray/2constructor-00.adoc[_» more..._]# Create a bit array of the specified length and bit value. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- xref:BloombergLP/bdlc/BitArray/2constructor-0c.adoc[BitArray]( std::size_t initialLength, bool value, xref:BloombergLP/bslma/Allocator.adoc[bslma::Allocator]* basicAllocator = 0); ---- [.small]#xref:BloombergLP/bdlc/BitArray/2constructor-0c.adoc[_» more..._]# == Parameters [cols="1,4"] |=== | Name| Description | *basicAllocator* | memory allocator; null uses the default | *initialLength* | initial number of bits in the array | *original* | array providing the value to copy | *value* | initial value for each bit |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#