Main Content

이 번역 페이지는 최신 내용을 담고 있지 않습니다. 최신 내용을 영문으로 보려면 여기를 클릭하십시오.

cancelAll

모든 작업 또는 태스크 취소

R2022a 이후

    설명

    예제

    cancelAll(p.FevalQueue)는 지정된 풀에서 대기 중이거나 실행 중인 모든 요소를 중지합니다.

    예제

    모두 축소

    병렬 풀을 만듭니다.

    pool = parpool;
    Starting parallel pool (parpool) using the 'Processes' profile ...
    Connected to the parallel pool (number of workers: 6).
    

    parfeval을 사용하여 pause(Inf)를 실행하고 출력값을 확인하지는 않습니다.

    f = parfeval(pool,@pause,0,Inf);

    풀에서 대기 중인 함수와 실행 중인 함수의 상태를 확인합니다.

    pool.FevalQueue
    ans = 
     FevalQueue with properties: 
    
            QueuedFutures: [0x0 parallel.FevalFuture]
           RunningFutures: [1x1 parallel.FevalFuture]
    
    

    cancelAll을 사용하여 FevalQueue에서 모든 Futures를 중지합니다.

    cancelAll(pool.FevalQueue)
    pool.FevalQueue
    ans = 
     FevalQueue with properties: 
    
            QueuedFutures: [0x0 parallel.FevalFuture]
           RunningFutures: [0x0 parallel.FevalFuture]
    
    

    입력 인수

    모두 축소

    백그라운드 풀에서 실행할 FevalFuture 객체의 대기열로, FevalFuture 스칼라와 FevalFuture 배열로 지정됩니다.

    버전 내역

    R2022a에 개발됨

    참고 항목

    | |