語言

Semaphore 建構函式

定義

多載

名稱 Description
Semaphore(Int32)

建立 Semaphore 一個符合指定許可數量及不公平公平設定的 。

Semaphore(Int32, Boolean)

以指定許可數量和公平度設定創建 a Semaphore

Semaphore(IntPtr, JniHandleOwnership)

建立 JNI 物件的 Managed 表示法時使用的建構函式;由運行時間呼叫。

Semaphore(Int32)

建立 Semaphore 一個符合指定許可數量及不公平公平設定的 。

[Android.Runtime.Register(".ctor", "(I)V", "")]
public Semaphore(int permits);
[<Android.Runtime.Register(".ctor", "(I)V", "")>]
new Java.Util.Concurrent.Semaphore : int -> Java.Util.Concurrent.Semaphore

參數

permits
Int32

初始可用的許可證數量。 此值可能為負值,此時必須先完成釋放,才能授予任何收購。

屬性

備註

建立 Semaphore 一個符合指定許可數量及不公平公平設定的 。

Java 文件 java.util.concurrent.Semaphore.Semaphore(int)

本頁部分內容為基於 Open Source Project 所創建與分享的作品,並依授權條款所描述的使用進行修改。

適用於

Semaphore(Int32, Boolean)

以指定許可數量和公平度設定創建 a Semaphore

[Android.Runtime.Register(".ctor", "(IZ)V", "")]
public Semaphore(int permits, bool fair);
[<Android.Runtime.Register(".ctor", "(IZ)V", "")>]
new Java.Util.Concurrent.Semaphore : int * bool -> Java.Util.Concurrent.Semaphore

參數

permits
Int32

初始可用的許可證數量。 此值可能為負值,此時必須先完成釋放,才能授予任何收購。

fair
Boolean

true 如果這個臂板能保證競爭許可先入先出,否則 false

屬性

備註

以指定許可數量和公平度設定創建 a Semaphore

Java 文件 java.util.concurrent.Semaphore.Semaphore(int, boolean)

本頁部分內容為基於 Open Source Project 所創建與分享的作品,並依授權條款所描述的使用進行修改。

適用於

Semaphore(IntPtr, JniHandleOwnership)

建立 JNI 物件的 Managed 表示法時使用的建構函式;由運行時間呼叫。

protected Semaphore(IntPtr javaReference, Android.Runtime.JniHandleOwnership transfer);
new Java.Util.Concurrent.Semaphore : nativeint * Android.Runtime.JniHandleOwnership -> Java.Util.Concurrent.Semaphore

參數

javaReference
IntPtr

nativeint

IntPtr,包含 Java Native Interface (JNI) 對象參考。

transfer
JniHandleOwnership

JniHandleOwnership,指出如何處理javaReference

備註

本頁部分內容為基於 Open Source Project 所創建與分享的作品,並依授權條款所描述的使用進行修改。

適用於