傳回來源可查詢可觀察序列的值,直到其他可查詢的可觀察序列產生值為止。
Namespace:System.Reactive.Linq
裝配: System.Reactive.Providers.dll) 中的 System.Reactive.Providers (
Syntax
'Declaration
<ExtensionAttribute> _
Public Shared Function TakeUntil(Of TSource, TOther) ( _
source As IQbservable(Of TSource), _
other As IObservable(Of TOther) _
) As IQbservable(Of TSource)
'Usage
Dim source As IQbservable(Of TSource)
Dim other As IObservable(Of TOther)
Dim returnValue As IQbservable(Of TSource)
returnValue = source.TakeUntil(other)
public static IQbservable<TSource> TakeUntil<TSource, TOther>(
this IQbservable<TSource> source,
IObservable<TOther> other
)
[ExtensionAttribute]
public:
generic<typename TSource, typename TOther>
static IQbservable<TSource>^ TakeUntil(
IQbservable<TSource>^ source,
IObservable<TOther>^ other
)
static member TakeUntil :
source:IQbservable<'TSource> *
other:IObservable<'TOther> -> IQbservable<'TSource>
JScript does not support generic types and methods.
類型參數
- TSource
來源的類型。
- TOther
另一種類型。
參數
- source
類型:System.Reactive.Linq.IQbservable< TSource>
要傳播專案的來源序列。
- 其他
類型:System.IObservable< TOther>
終止來源序列專案傳播的可觀察序列。
傳回值
類型:System.Reactive.Linq.IQbservable< TSource>
可查詢的可觀察序列,包含來源序列的專案,到另一個序列中斷進一步傳播的點為止。
使用注意事項
在 Visual Basic 和 C# 中,您可以在IQbservable< TSource > 類型的任何物件上呼叫此方法作為實例方法。 使用執行個體方法語法呼叫這個方法時,請省略第一個參數。 如需詳細資訊,請參閱 或 。