RuntimeInformation.IsOSPlatform(OSPlatform) RuntimeInformation.IsOSPlatform(OSPlatform) RuntimeInformation.IsOSPlatform(OSPlatform) Method

Definition

Indicates whether the current application is running on the specified platform.

public:
 static bool IsOSPlatform(System::Runtime::InteropServices::OSPlatform osPlatform);
public static bool IsOSPlatform (System.Runtime.InteropServices.OSPlatform osPlatform);
static member IsOSPlatform : System.Runtime.InteropServices.OSPlatform -> bool

Parameters

osPlatform
OSPlatform OSPlatform OSPlatform

A platform.

Returns

true if the current app is running on the specified platform; otherwise, false.

Applies to