SemaphoreAcl.OpenExisting(String, SemaphoreRights) Method
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Opens a specified named semaphore, if it already exists, and applies the desired access rights.
public:
static System::Threading::Semaphore ^ OpenExisting(System::String ^ name, System::Security::AccessControl::SemaphoreRights rights);
public static System.Threading.Semaphore OpenExisting(string name, System.Security.AccessControl.SemaphoreRights rights);
static member OpenExisting : string * System.Security.AccessControl.SemaphoreRights -> System.Threading.Semaphore
Public Shared Function OpenExisting (name As String, rights As SemaphoreRights) As Semaphore
- name
- String
The name of the semaphore to be opened. If it's prefixed by "Global", it refers to a machine-wide semaphore. If it's prefixed by "Local", or doesn't have a prefix, it refers to a session-wide semaphore. Both prefix and name are case-sensitive.
- rights
- SemaphoreRights
The desired access rights to apply to the returned semaphore.
An existing named semaphore.
name
is null
.
name
is an empty string.
The named semaphore does not exist or is invalid.
The named semaphore exists, but the user does not have the security access required to use it.
Produkt | Versiounen |
---|---|
.NET | 8 (package-provided), 9 (package-provided), 10 (package-provided) |
.NET Standard | 2.0 (package-provided) |
Windows Desktop | 6, 7, 8, 9, 10 |
Feedback zu .NET
.NET ass en Open-Source-Projet. Wielt e Link, fir Feedback ze ginn: