Bewerken

Delen via


Marshal.GetThreadFromFiberCookie(Int32) Method

Definition

Caution

The GetThreadFromFiberCookie method has been deprecated. Use the hosting API to perform this operation.

Converts a fiber cookie into the corresponding Thread instance.

public:
 static System::Threading::Thread ^ GetThreadFromFiberCookie(int cookie);
public static System.Threading.Thread GetThreadFromFiberCookie (int cookie);
[System.Obsolete("The GetThreadFromFiberCookie method has been deprecated.  Use the hosting API to perform this operation.", false)]
public static System.Threading.Thread GetThreadFromFiberCookie (int cookie);
[System.Obsolete("The GetThreadFromFiberCookie method has been deprecated.  Use the hosting API to perform this operation.", false)]
[System.Security.SecurityCritical]
public static System.Threading.Thread GetThreadFromFiberCookie (int cookie);
static member GetThreadFromFiberCookie : int -> System.Threading.Thread
[<System.Obsolete("The GetThreadFromFiberCookie method has been deprecated.  Use the hosting API to perform this operation.", false)>]
static member GetThreadFromFiberCookie : int -> System.Threading.Thread
[<System.Obsolete("The GetThreadFromFiberCookie method has been deprecated.  Use the hosting API to perform this operation.", false)>]
[<System.Security.SecurityCritical>]
static member GetThreadFromFiberCookie : int -> System.Threading.Thread
Public Shared Function GetThreadFromFiberCookie (cookie As Integer) As Thread

Parameters

cookie
Int32

An integer that represents a fiber cookie.

Returns

A thread that corresponds to the cookie parameter.

Attributes

Exceptions

The cookie parameter is 0.

Remarks

Fiber cookies are opaque tokens that are used by the host when alerting the common language runtime to its fiber-scheduling decisions. They consist of a stack and register context.

Applies to

See also