[#prevector-0c-2constructor-0e] = xref:prevector-0c.adoc[prevector]::prevector :relfileprefix: ../ :mrdocs: Constructors == Synopses Declared in `<prevector.h>` Constructs an empty container. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- xref:prevector-0c/2constructor-0c.adoc[prevector]() = default; ---- [.small]#xref:prevector-0c/2constructor-0c.adoc[_» more..._]# Constructs a copy of `other`. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- xref:prevector-0c/2constructor-0a.adoc[prevector](xref:prevector-0c.adoc[prevector<N, T, Size, Diff>] const& other); ---- [.small]#xref:prevector-0c/2constructor-0a.adoc[_» more..._]# Constructs a container by moving the contents of `other`, leaving it empty. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- xref:prevector-0c/2constructor-01.adoc[prevector](xref:prevector-0c.adoc[prevector<N, T, Size, Diff>]&& other) noexcept; ---- [.small]#xref:prevector-0c/2constructor-01.adoc[_» more..._]# Constructs a container with `n` value‐initialized elements. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- explicit xref:prevector-0c/2constructor-02.adoc[prevector](xref:prevector-0c/size_type.adoc[size_type] n); ---- [.small]#xref:prevector-0c/2constructor-02.adoc[_» more..._]# Constructs a container with `n` copies of `val`. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- explicit xref:prevector-0c/2constructor-0d.adoc[prevector]( xref:prevector-0c/size_type.adoc[size_type] n, T const& val); ---- [.small]#xref:prevector-0c/2constructor-0d.adoc[_» more..._]# Constructs a container from the elements in the range [first, last).] [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- template<std::input_iterator InputIterator> xref:prevector-0c/2constructor-09.adoc[prevector]( InputIterator first, InputIterator last); ---- [.small]#xref:prevector-0c/2constructor-09.adoc[_» more..._]# == Parameters [cols="1,4"] |=== | Name| Description | *other* | The container to copy from. | *n* | The number of elements to create. | *val* | The value to copy into each element. | *first* | Iterator to the first element to copy. | *last* | Iterator one past the last element to copy. |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#