简体   繁体   English

> - 运算符在RxSwift中意味着什么?它在哪里记录?

[英]What does the >- operator mean in RxSwift and where is it documented?

I've seen the >- operator in various code fragments involving RxSwift (eg https://github.com/ReactiveX/RxSwift/issues/35 ), but can't find any documentation on it. 我在涉及RxSwift的各种代码片段中看到了>-运算符(例如https://github.com/ReactiveX/RxSwift/issues/35 ),但找不到任何文档。 What does it mean? 这是什么意思?

Here's an example: 这是一个例子:

combineLatest(emailIsValid, passwordIsValid)
    >- and
    >- signupButton.rx_subscribeEnabledTo
    >- disposeBag.addDisposable

The >- operator is called the "pipe-forward operator" and it was removed in this commit in favor of protocol extensions, once they were possible in Swift. >-运算符被称为“管道转发运算符”,它在此提交中被删除, 利于协议扩展,一旦它们在Swift中可行。

It was just the best way to do it at that moment, given Swift's abilities. 考虑到斯威夫特的能力,这只是当时做到这一点的最佳方式。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM