Observable.Generate<TState, TResult> メソッド (TState, Func<TState, Boolean>, Func<TState, TState>, Func<TState, TResult>, Func<TState, DateTimeOffset>, IScheduler)

状態が失敗するまで初期状態から状態を反復処理することによって、監視可能なシーケンスを生成します。

Namespace:System.Reactive.Linq
アセンブリ: System.Reactive (System.Reactive.dll)

構文

'Declaration
Public Shared Function Generate(Of TState, TResult) ( _
    initialState As TState, _
    condition As Func(Of TState, Boolean), _
    iterate As Func(Of TState, TState), _
    resultSelector As Func(Of TState, TResult), _
    timeSelector As Func(Of TState, DateTimeOffset), _
    scheduler As IScheduler _
) As IObservable(Of TResult)
'Usage
Dim initialState As TState
Dim condition As Func(Of TState, Boolean)
Dim iterate As Func(Of TState, TState)
Dim resultSelector As Func(Of TState, TResult)
Dim timeSelector As Func(Of TState, DateTimeOffset)
Dim scheduler As IScheduler
Dim returnValue As IObservable(Of TResult)

returnValue = Observable.Generate(initialState, _
    condition, iterate, resultSelector, _
    timeSelector, scheduler)
public static IObservable<TResult> Generate<TState, TResult>(
    TState initialState,
    Func<TState, bool> condition,
    Func<TState, TState> iterate,
    Func<TState, TResult> resultSelector,
    Func<TState, DateTimeOffset> timeSelector,
    IScheduler scheduler
)
public:
generic<typename TState, typename TResult>
static IObservable<TResult>^ Generate(
    TState initialState, 
    Func<TState, bool>^ condition, 
    Func<TState, TState>^ iterate, 
    Func<TState, TResult>^ resultSelector, 
    Func<TState, DateTimeOffset>^ timeSelector, 
    IScheduler^ scheduler
)
static member Generate : 
        initialState:'TState * 
        condition:Func<'TState, bool> * 
        iterate:Func<'TState, 'TState> * 
        resultSelector:Func<'TState, 'TResult> * 
        timeSelector:Func<'TState, DateTimeOffset> * 
        scheduler:IScheduler -> IObservable<'TResult> 
JScript does not support generic types and methods.

型パラメーター

  • TState
    状態の種類。
  • TResult
    結果の型。

パラメーター

  • initialState
    種類: TState
    初期状態。
  • 繰り返し (iterate)
    種類: System.Func<TState、TState>
    反復ステップ関数。
  • resultSelector
    種類: System.Func<TState、TResult>
    シーケンスで生成された結果のセレクター関数。
  • timeSelector
    種類: System.Func<TState、 DateTimeOffset>
    反復ごとに生成される値の速度を制御する時間セレクター関数。

戻り値

種類: System.IObservable<TResult>
生成されたシーケンス。

参照

リファレンス

Observable クラス

オーバーロードの生成

System.Reactive.Linq 名前空間