Back to Arangodb

Random Access Sequence

3rdParty/boost/1.78.0/libs/mpl/doc/refmanual/random-access-sequence.html

3.12.9.12.6 KB
Original Source

| Prev Next | Back Along | Up Home | Full TOC | Front Page / Sequences / Concepts / Random Access Sequence |

Random Access Sequence

Description

A Random Access Sequence is a Bidirectional Sequence whose iterators model Random Access Iterator. A random access sequence guarantees amortized constant time access to an arbitrary sequence element.

Refinement of

Bidirectional Sequence

Expression requirements

In addition to the requirements defined in Bidirectional Sequence, for any Random Access Sequence s the following must be met:

ExpressionTypeComplexity
begin<s>::typeRandom Access IteratorAmortized constant time
end<s>::typeRandom Access IteratorAmortized constant time
at<s,n>::typeAny typeAmortized constant time

Expression semantics

Semantics of an expression is defined only where it differs from, or is not defined in Bidirectional Sequence.

ExpressionSemantics
at<s,n>::typeThe nth element from the beginning of the sequence; see at.

Models

See also

Sequences, Bidirectional Sequence, Extensible Sequence, Random Access Iterator, begin / end, at

| Prev Next | Back Along | Up Home | Full TOC |

Copyright © 2001-2009 Aleksey Gurtovoy and David Abrahams Distributed under the Boost Software License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) |