std::forward_list
提供:cppreference.com
|
|
This page has been machine-translated from the English version of the wiki using Google Translate.
The translation may contain errors and awkward wording. Hover over text to see the original version. You can help to fix errors and improve the translation. For instructions click here. |
| Defined in header <forward_list>
|
||
| template< class T, |
(C + + 11以来) | |
Forward listは、任意の位置に対して高速な要素の挿入と削除をサポートするコンテナです。 高速なランダムアクセスはサポートされていません。 単方向リストとして実装されており、Cでの実装と比べて本質的なオーバーヘッドがありません。 双方向のイテレーションが必要でなければ、std::listに比べて使用メモリが少なくなります。
std::forward_listはContainer(size()メンバ関数を除く)、AllocatorAwareContainerとSequenceContainerの要件を満たします.
[編集] メンバータイプ
| メンバー·タイプ | Definition |
value_type
|
T
|
allocator_type
|
Allocator
|
size_type
|
符号なし整数型(通常size_t)
Original: Unsigned integral type (usually size_t) The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. |
difference_type
|
Signed integer type (usually ptrdiff_t) |
reference
|
value_type&
|
const_reference
|
const value_type&
|
pointer
|
std::allocator_traits<Allocator>::pointer |
const_pointer
|
std::allocator_traits<Allocator>::const_pointer |
iterator
|
ForwardIterator
|
const_iterator
|
定数前方反復子
Original: Constant forward iterator The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. |
[編集] メンバ関数
forward_listを構築します Original: constructs the forward_list The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (パブリックメンバ関数) | |
destructs the forward_list (パブリックメンバ関数) | |
| コンテナに値を割り当てます Original: assigns values to the container The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (パブリックメンバ関数) | |
| コンテナに値を割り当てます Original: assigns values to the container The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (パブリックメンバ関数) | |
| 関連したアロケータを返す Original: returns the associated allocator The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (パブリックメンバ関数) | |
要素へのアクセス | |
| 最初の要素にアクセスします Original: access the first element The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (パブリックメンバ関数) | |
Original: Iterators The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. | |
| 先頭の前に位置する要素を指すイテレータを返します (パブリックメンバ関数) | |
| 先頭を指すイテレータを返します (パブリックメンバ関数) | |
| 末尾を指すイテレータを返す Original: returns an iterator to the end The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (パブリックメンバ関数) | |
Original: Capacity The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. | |
| コンテナが空であるかどうかをチェックします (パブリックメンバ関数) | |
| 要素の最大数を返します Original: returns the maximum possible number of elements The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (パブリックメンバ関数) | |
修正 | |
| 全ての要素を削除します (パブリックメンバ関数) | |
| 挿入要素の後に要素を Original: inserts elements after an element The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (パブリックメンバ関数) | |
| 要素の後にその場で要素を構成します Original: constructs elements in-place after an element The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (パブリックメンバ関数) | |
| 消去さの要素の後に要素 Original: erases an element after an element The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (パブリックメンバ関数) | |
| 先頭に挿入要素 Original: inserts elements to the beginning The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (パブリックメンバ関数) | |
| 冒頭でその場で要素を構成します Original: constructs elements in-place at the beginning The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (パブリックメンバ関数) | |
| 最初の要素を削除します Original: removes the first element The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (パブリックメンバ関数) | |
| changes the number of elements stored (パブリックメンバ関数) | |
| コンテナの内容をスワップします (パブリックメンバ関数) | |
Original: Operations The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. | |
| 2ソートされたリストをマージします Original: merges two sorted lists The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (パブリックメンバ関数) | |
| 別 forward_listから要素を移動します Original: moves elements from another forward_list The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (パブリックメンバ関数) | |
| 特定の条件を満たす要素を削除します Original: removes elements satisfying specific criteria The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (パブリックメンバ関数) | |
| 要素の順序を反転します Original: reverses the order of the elements The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (パブリックメンバ関数) | |
| 連続した重複要素を削除します Original: removes consecutive duplicate elements The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (パブリックメンバ関数) | |
| ソート要素 Original: sorts the elements The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (パブリックメンバ関数) | |
[編集] 非メンバ関数
| 辞書的にforward_list内の値を比較します Original: lexicographically compares the values in the forward_list The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (関数テンプレート) | |
| 特殊化されたstd::swapアルゴリズム (関数テンプレート) | |