cancelAll
説明
cancelAll(
は、バックグラウンド プールで待機中または実行中のすべての要素を停止します。p.FevalQueue
)
例
バックグラウンドで実行されているすべての関数の停止
バックグラウンド プールを作成します。parfeval
を使用して、出力を取得せずに pause(Inf)
を実行します。
pool = backgroundPool; f = parfeval(pool,@pause,0,Inf);
プール内で待機中および実行中の関数のステータスを確認します。
pool.FevalQueue
ans = FevalQueue with properties: QueuedFutures: [1x1 parallel.FevalFuture] RunningFutures: [0x0 parallel.FevalFuture]
cancelAll
を使用して、FevalQueue
内のすべての Futures
を停止します。
cancelAll(pool.FevalQueue) pool.FevalQueue
ans = FevalQueue with properties: QueuedFutures: [0x0 parallel.FevalFuture] RunningFutures: [0x0 parallel.FevalFuture]
入力引数
p.FevalQueue
— バックグラウンド プールで実行する FevalFuture
オブジェクトのキュー
FevalFuture
スカラー | FevalFuture
配列
バックグラウンド プールで実行する FevalFuture
オブジェクトのキュー。FevalFuture
スカラーおよび FevalFuture
配列として指定します。
バージョン履歴
R2022a で導入
MATLAB コマンド
次の MATLAB コマンドに対応するリンクがクリックされました。
コマンドを MATLAB コマンド ウィンドウに入力して実行してください。Web ブラウザーは MATLAB コマンドをサポートしていません。
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)