Zip
-
Undocumented
See moreDeclaration
Swift
public struct Zip3Sequence < Sequence1: Sequence, Sequence2: Sequence, Sequence3: Sequence >: IteratorProtocol, Sequence
-
Lazy sequence zipping two
See moreSequence
values together to the longest of the two sequences, filling in the others with the givenfill1
, andfill2
values.Declaration
Swift
public struct ZipToLongest2Sequence <Sequence1: Sequence, Sequence2: Sequence> : IteratorProtocol, Sequence
-
Lazy sequence zipping three
See moreSequence
values together to the longest of the three sequences, filling in the others with the givenfill1
,fill2
, andfill3
values.Declaration
Swift
public struct ZipToLongest3Sequence <Sequence1: Sequence, Sequence2: Sequence, Sequence3: Sequence> : IteratorProtocol, Sequence
-
Lazy
Sequence
zipping threeSequence
values together.Note
This should be deprecated when
Variadic Generics
are implemented in Swift. As outlined in the Generics ManifestoModified by James Bean.
Declaration
Swift
@inlinable public func zip <Sequence1,Sequence2,Sequence3> ( _ sequence1: Sequence1, _ sequence2: Sequence2, _ sequence3: Sequence3 ) -> Zip3Sequence<Sequence1,Sequence2,Sequence3>
-
Declaration
Swift
public func zip <Sequence1,Sequence2> ( _ sequence1: Sequence1, _ sequence2: Sequence2, fill1: Sequence1.Element, fill2: Sequence2.Element ) -> ZipToLongest2Sequence<Sequence1,Sequence2>
Return Value
A
ZipToLongest2Sequence
for the two given sequences, usingfill1
andfill2
as default values if the other sequence is longer. -
Declaration
Swift
public func zip <Sequence1,Sequence2> ( _ sequence1: Sequence1, _ sequence2: Sequence2, fill: Sequence1.Element ) -> ZipToLongest2Sequence<Sequence1,Sequence2> where Sequence1.Element == Sequence2.Element
Return Value
A
ZipToLongest2Sequence
for the two given sequences, usingfill
andfill
as default values if the other sequence is longer. -
Declaration
Swift
public func zip <Sequence1,Sequence2,Sequence3> ( _ sequence1: Sequence1, _ sequence2: Sequence2, _ sequence3: Sequence3, fill1: Sequence1.Element, fill2: Sequence2.Element, fill3: Sequence3.Element ) -> ZipToLongest3Sequence<Sequence1,Sequence2,Sequence3>
Return Value
A
ZipToLongest3Sequence
for the three given sequences, usingfirstFill
,secondFill
, andthirdFill
as default values if the other sequences are longer. -
Declaration
Swift
public func zip <Sequence1,Sequence2,Sequence3> ( _ sequence1: Sequence1, _ sequence2: Sequence2, _ sequence3: Sequence3, fill: Sequence1.Element ) -> ZipToLongest3Sequence<Sequence1,Sequence2,Sequence3> where Sequence1.Element == Sequence2.Element, Sequence2.Element == Sequence3.Element
Return Value
A
ZipToLongest3Sequence
for the three given sequences, usingfill
as a default value if the other sequences are longer.