Espaces de noms
Variantes
Actions

<div class="t-tr-text">Concepts C + +:<div class="t-tr-dropdown"><div><div><div class="t-tr-dropdown-arrow-border"></div><div class="t-tr-dropdown-arrow"></div><div class="t-tr-dropdown-h">Original:</div><div class="t-tr-dropdown-orig">C++ concepts:</div><div class="t-tr-dropdown-notes">The text has been machine-translated via [http://translate.google.com Google Translate].<br/> You can help to correct and verify the translation. Click [http://en.cppreference.com/w/Cppreference:MachineTranslations here] for instructions.</div></div></div></div></div> SequenceContainer

De cppreference.com
< cpp‎ | concept

 
 
C + + concepts
De base
Original:
Basic
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Bibliothèque échelle
Original:
Library-Wide
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Récipient
Original:
Container
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Éléments de conteneurs
Original:
Container Elements
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Iterator
Original:
Iterator
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Nombres aléatoires
Original:
Random Numbers
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Simultanéité
Original:
Concurrency
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
BasicLockable (C++11)
Lockable (C++11)
TimedLockable (C++11)
Mutex (C++11)
TimedMutex (C++11)
Autre
Original:
Other
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
 
Un SequenceContainer est un Container qui stocke les objets du même type dans un agencement linéaire .
Original:
A SequenceContainer is a Container that stores objects of the same type in a linear arrangement.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

Sommaire

[modifier]Exigences

Legend
Original:
Legend
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

X
Type de conteneur
Original:
Container type
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
T
Type d'élément
Original:
Element type
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
a, b
Objets de X type
Original:
Objects of type X
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
t
Objet de T type
Original:
Object of type T
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
n
Entier positif
Original:
Positive integer
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
i, j
InputIterators dénotant une plage valide
Original:
InputIterators denoting a valid range
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
ilstd::initializer_list<T>
args
Pack paramètre
Original:
Parameter pack
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
p, q
const_iterators dans a
Original:
const_iterators in a
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.


expressionreturn typeeffectspreconditionpostcondition
X(n,t)Constructs a SequenceContainer containing n copies of t T CopyInsertablestd::distance(begin(),end())== n
X(i,j)Constructs a SequenceContainer equivalent to the range [i,j)
  • T EmplaceConstructible
  • (
    seulement pour std :: vector
    Original:
    only for std::vector
    The text has been machine-translated via Google Translate.
    You can help to correct and verify the translation. Click here for instructions.
    )
    Si les itérateurs ne sont pas ForwardIterators, T doit être CopyInsertable
    Original:
    (
    seulement pour std :: vector
    Original:
    only for std::vector
    The text has been machine-translated via Google Translate.
    You can help to correct and verify the translation. Click here for instructions.
    )
    If the iterators are not ForwardIterators, T must be CopyInsertable
    The text has been machine-translated via Google Translate.
    You can help to correct and verify the translation. Click here for instructions.
std::distance(begin(),end())==

std::distance(i,j)

X(il)X(il.begin(),il.end)
a = ilX&Assigns the range represented by il into a T CopyInsertable and CopyAssignable Existing elements of a are destroyed or assigned to
a.emplace(p,args)iterator Insert an object constructed with std::forward<Args>(args) before p
a.emplace(p,t)iterator Inserts a copy of t before i
a.insert(p,n,t)iteratorInserts n copies of t before i T CopyInsertable and CopyAssignable
a.insert(p,i,j)iteratorInserts copies of elements in [i, j) before pEach iterator in [i,j) is dereferenced once
a.insert(p, il)iteratora.insert(p,il.begin(),il.end())
a.erase(q)iteratorErases the element pointed to by q (
std :: deque, std :: vector
Original:
std::deque, std::vector
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
)
T MoveAssignable
a.erase(p,q)iteratorErases elements in [p,q) (
std :: deque, std :: vector
Original:
std::deque, std::vector
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
)
T MoveAssignable
a.clear()voidDestroys all elements in a
  • Toutes les références sont invalidés
    Original:
    All references are invalidated
    The text has been machine-translated via Google Translate.
    You can help to correct and verify the translation. Click here for instructions.
  • a.empty()==true
a.assign(i,j)voidReplaces elements in a with a copy of [i, j)Each iterator in [i,j) is dereferenced once
a.assign(il)voida.assign(il.begin(),il.end())
a.assign(n,t)void Replaces elements in a with n copies of tT CopyInsertable and CopyAssignable

[modifier]Opérations optionnelles

[modifier]SequenceContainers dans la bibliothèque standard

(depuis C++11)
tableau statique contigu
(classe générique)[edit]
tableau dynamique contigu
(classe générique)[edit]
file d'attente à deux bouts
(classe générique)[edit]
(depuis C++11)
liste simplement chaînée
(classe générique)[edit]
liste doublement chaînée
(classe générique)[edit]

[modifier]Compromis / notes d'utilisation

std::array
Accès rapide mais nombre fixe d'éléments
Original:
Fast access but fixed 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.
std::vector
Accès rapide mais surtout inefficace insertions / suppressions
Original:
Fast access but mostly inefficient insertions/deletions
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
std::list
std::forward_list
Insertion efficace / délétion dans le milieu de la séquence
Original:
Efficient insertion/deletion in the middle of the sequence
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
std::deque
Insertion efficace / suppression, au début et à la fin de la séquence
Original:
Efficient insertion/deletion at the beginning and at the end of the sequence
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
close