Semaphore Constructor (Int32, Int32, String)

For apps that target Windows Phone OS 7.0 and 7.1, do not use this member in your app. If you do, your code will throw a MethodAccessException. This member is security-critical, which restricts it to internal use by the .NET Framework for Windows Phone class library.

[SECURITY CRITICAL]

[ This article is for Windows Phone 8 developers. If you’re developing for Windows 10, see the latest documentation. ]

Initializes a new instance of the Semaphore class, specifying the maximum number of concurrent entries, optionally reserving some entries for the calling thread, and optionally specifying the name of a system semaphore object.

Namespace: System.Threading
Assembly: System (in System.dll)

Syntax

<SecurityCriticalAttribute> _
Public Sub New ( _
    initialCount As Integer, _
    maximumCount As Integer, _
    name As String _
)
[SecurityCriticalAttribute]
public Semaphore(
    int initialCount,
    int maximumCount,
    string name
)

Parameters

  • initialCount
    Type: System..::.Int32
    The initial number of requests for the semaphore that can be granted concurrently.
  • maximumCount
    Type: System..::.Int32
    The maximum number of requests for the semaphore that can be granted concurrently.

Version Information

Windows Phone OS

Supported in: 8.1, 8.0

See Also

Reference

Semaphore Class

Semaphore Overload

System.Threading Namespace

Other Resources

Managed Threading

[7722a333-b974-47a2-a7c0-f09097fb644e]