SpinWait.SpinOnce 메서드

정의

오버로드

SpinOnce()

단일 회전을 수행합니다.

SpinOnce(Int32)

단일 스핀을 수행하고 최소 스핀 수 이후에 Sleep(Int32)를 호출합니다.

SpinOnce()

단일 회전을 수행합니다.

public:
 void SpinOnce();
public void SpinOnce ();
member this.SpinOnce : unit -> unit
Public Sub SpinOnce ()

설명

이 메서드는 일반적으로 루프에서 호출되며 이 인스턴스에서 지금까지 호출된 횟 SpinOnce 수에 따라 동작이 변경될 수 있습니다. 각 회전의 결과 SpinWait 메서드가 호출 됩니다. 횟수의 개수를 유지 SpinOnce 가 호출 임계값 개수에 도달한 후는 Yield 메서드가 호출 됩니다.

추가 정보

적용 대상

SpinOnce(Int32)

단일 스핀을 수행하고 최소 스핀 수 이후에 Sleep(Int32)를 호출합니다.

public:
 void SpinOnce(int sleep1Threshold);
public void SpinOnce (int sleep1Threshold);
member this.SpinOnce : int -> unit
Public Sub SpinOnce (sleep1Threshold As Integer)

매개 변수

sleep1Threshold
Int32

Thread.Sleep(1)을 사용할 수 있는 최소 스핀 수입니다. -1 값은 Thread.Sleep(1)의 사용을 비활성화합니다.

예외

sleep1Threshold이 -1보다 작습니다.

설명

이 메서드는 일반적으로 루프에서 호출되며 이 인스턴스에서 지금까지 호출된 횟 SpinOnce() 수에 따라 동작이 변경될 수 있습니다.

적용 대상