BidirectionalCollection

E427892

BidirectionalCollection is a Swift standard library protocol for collections whose elements can be traversed efficiently in both forward and backward directions.

All labels observed (1)

Label Occurrences
BidirectionalCollection canonical 1

How this entity was disambiguated

Statements (48)

Predicate Object
instanceOf Swift protocol
collection protocol
availableOnPlatform Linux (Swift) NERFINISHED
iOS NERFINISHED
macOS NERFINISHED
tvOS NERFINISHED
watchOS NERFINISHED
backwardTraversalComplexity O(1) per step
conformingTypesMustSupport bidirectional index movement in O(1) time
conformsTo Sequence (via Collection)
definedInLanguage Swift NERFINISHED
designGoal provide efficient bidirectional traversal semantics
documentationURL https://developer.apple.com/documentation/swift/bidirectionalcollection
elementAccessComplexity O(1)
extends Collection
forwardTraversalComplexity O(1) per step
hasAssociatedType Element
Index
hasSubProtocol RandomAccessCollection
indexTypeMustConformTo Comparable
introducedIn Swift 1.x era
languageFeatureCategory Generics
module Swift NERFINISHED
partOf Swift Standard Library NERFINISHED
primaryUse collections that can be traversed efficiently in both directions
refinedFrom Collection protocol
requiresIndicesToForm a finite range
requiresMethod index(after:)
index(before:)
requiresProperty endIndex
indices
isEmpty
startIndex
requiresSubscript subscript(position: Index) -> Element
requiresTraversalDirection backward
forward
superProtocol Collection
supportsOperation backward index movement
bidirectional for-in loops
reverse iteration
typicalConformingType Array
ArraySlice NERFINISHED
ClosedRange
ContiguousArray
Range
String
Substring
usedFor algorithms that need to traverse collections from the end

How these facts were elicited

Referenced by (1)

Full triples — surface form annotated when it differs from this entity's canonical label.

Swift Standard Library includesProtocol BidirectionalCollection