【发布时间】:2021-06-20 16:55:44
【问题描述】:
我有以下代码
private var codeState : AnyPublisher<((Bool,Bool,Bool,Bool),(Bool,Bool)), Never> {
let publ1 = Publishers.CombineLatest4(firstCodeAnyPublisher,secondCodeAnyPublisher,thirdCodeAnyPublisher,fourthCodeAnyPublisher)
let pub2 = Publishers.CombineLatest(fifthCodeAnyPublisher, sixthCodeAnyPublisher)
return publ1.combineLatest(pub2)
.eraseToAnyPublisher()
}
此操作生成具有两个布尔元组的任何发布者 如何将它们转换为具有以下一个元组的发布者
AnyPublisher<(Bool,Bool,Bool,Bool,Bool,Bool), Never>
【问题讨论】:
标签: ios tuples combine publisher