IGLib
1.7.2
The IGLib base library EXTENDED - with other lilbraries and applications.
|
OSPlatform represents a particular operating system platform More...
Classes | |
struct | OSVERSIONINFOEX |
Public Types | |
enum | ProductType { ProductType.Unknown, ProductType.WorkStation, ProductType.DomainController, ProductType.Server } |
Product Type Enumeration used for Windows More... | |
Public Member Functions | |
OSPlatform (PlatformID platform, Version version) | |
Construct from a platform ID and version More... | |
OSPlatform (PlatformID platform, Version version, ProductType product) | |
Construct from a platform ID, version and product type More... | |
Static Public Attributes | |
static readonly PlatformID | UnixPlatformID_Microsoft = (PlatformID)4 |
Platform ID for Unix as defined by Microsoft .NET 2.0 and greater More... | |
static readonly PlatformID | UnixPlatformID_Mono = (PlatformID)128 |
Platform ID for Unix as defined by Mono More... | |
static readonly PlatformID | XBoxPlatformID = (PlatformID)5 |
Platform ID for XBox as defined by .NET and Mono, but not CF More... | |
static readonly PlatformID | MacOSXPlatformID = (PlatformID)6 |
Platform ID for MacOSX as defined by .NET and Mono, but not CF More... | |
Properties | |
static OSPlatform | CurrentPlatform [get] |
Get the OSPlatform under which we are currently running More... | |
PlatformID | Platform [get] |
Get the platform ID of this instance More... | |
Version | Version [get] |
Get the Version of this instance More... | |
ProductType | Product [get] |
Get the Product Type of this instance More... | |
bool | IsWindows [get] |
Return true if this is a windows platform More... | |
bool | IsUnix [get] |
Return true if this is a Unix or Linux platform More... | |
bool | IsWin32S [get] |
Return true if the platform is Win32S More... | |
bool | IsWin32Windows [get] |
Return true if the platform is Win32Windows More... | |
bool | IsWin32NT [get] |
Return true if the platform is Win32NT More... | |
bool | IsWinCE [get] |
Return true if the platform is Windows CE More... | |
bool | IsXbox [get] |
Return true if the platform is Xbox More... | |
bool | IsMacOSX [get] |
Return true if the platform is MacOSX More... | |
bool | IsWin95 [get] |
Return true if the platform is Windows 95 More... | |
bool | IsWin98 [get] |
Return true if the platform is Windows 98 More... | |
bool | IsWinME [get] |
Return true if the platform is Windows ME More... | |
bool | IsNT3 [get] |
Return true if the platform is NT 3 More... | |
bool | IsNT4 [get] |
Return true if the platform is NT 4 More... | |
bool | IsNT5 [get] |
Return true if the platform is NT 5 More... | |
bool | IsWin2K [get] |
Return true if the platform is Windows 2000 More... | |
bool | IsWinXP [get] |
Return true if the platform is Windows XP More... | |
bool | IsWin2003Server [get] |
Return true if the platform is Windows 2003 Server More... | |
bool | IsNT6 [get] |
Return true if the platform is NT 6 More... | |
bool | IsNT60 [get] |
Return true if the platform is NT 6.0 More... | |
bool | IsNT61 [get] |
Return true if the platform is NT 6.1 More... | |
bool | IsNT62 [get] |
Return true if the platform is NT 6.2 More... | |
bool | IsNT63 [get] |
Return true if the platform is NT 6.3 More... | |
bool | IsVista [get] |
Return true if the platform is Vista More... | |
bool | IsWin2008Server [get] |
Return true if the platform is Windows 2008 Server (original or R2) More... | |
bool | IsWin2008ServerR1 [get] |
Return true if the platform is Windows 2008 Server (original) More... | |
bool | IsWin2008ServerR2 [get] |
Return true if the platform is Windows 2008 Server R2 More... | |
bool | IsWin2012Server [get] |
Return true if the platform is Windows 2012 Server (original or R2) More... | |
bool | IsWin2012ServerR1 [get] |
Return true if the platform is Windows 2012 Server (original) More... | |
bool | IsWin2012ServerR2 [get] |
Return true if the platform is Windows 2012 Server R2 More... | |
bool | IsWindows7 [get] |
Return true if the platform is Windows 7 More... | |
bool | IsWindows8 [get] |
Return true if the platform is Windows 8 More... | |
bool | IsWindows81 [get] |
Return true if the platform is Windows 8.1 More... | |
bool | IsWindows10 [get] |
Return true if the platform is Windows 10 More... | |
bool | IsWindowsServer10 [get] |
Return true if the platform is Windows Server. This is named Windows Server 10 to distinguish it from previous versions of Windows Server. More... | |
Private Member Functions | |
static bool | GetVersionEx (ref OSVERSIONINFOEX osvi) |
static int | uname (IntPtr buf) |
Static Private Member Functions | |
static Version | GetWindows81PlusVersion (Version version) |
Gets the actual OS Version, not the incorrect value that might be returned for Win 8.1 and Win 10 More... | |
static bool | CheckIfIsMacOSX (PlatformID platform) |
Private Attributes | |
PlatformID | platform |
Version | version |
ProductType | product |
Static Private Attributes | |
static OSPlatform | currentPlatform |
OSPlatform represents a particular operating system platform
|
inline |
Construct from a platform ID and version
|
inline |
Construct from a platform ID, version and product type
|
inlinestaticprivate |
Gets the actual OS Version, not the incorrect value that might be returned for Win 8.1 and Win 10
If an application is not manifested as Windows 8.1 or Windows 10, the version returned from Environment.OSVersion will not be 6.3 and 10.0 respectively, but will be 6.2 and 6.3. The correct value can be found in the registry.
version | The original version |
|
private |
|
private |
|
inlinestaticprivate |
|
private |
|
private |
|
private |
|
staticprivate |
|
static |
Platform ID for Unix as defined by Microsoft .NET 2.0 and greater
Referenced by NUnit.Framework.Internal.PlatformDetectionTests.DetectUnixUnderMicrosoftDotNet().
|
static |
Platform ID for Unix as defined by Mono
Referenced by NUnit.Framework.Internal.PlatformDetectionTests.DetectUnixUnderMono().
|
static |
Platform ID for XBox as defined by .NET and Mono, but not CF
|
static |
Platform ID for MacOSX as defined by .NET and Mono, but not CF
|
staticget |
Get the OSPlatform under which we are currently running
Referenced by NUnit.Framework.Attributes.TestCaseAttributeTests.CanExcludePlatform(), NUnit.Framework.Attributes.TestCaseAttributeTests.CanIncludePlatform(), NUnit.Framework.Internal.PlatformDetectionTests.CheckRuntimePlatforms(), NUnit.Framework.Attributes.ApplyToTestTests.GetMyPlatform(), and NUnit.Framework.Internal.PlatformHelper.PlatformHelper().
|
get |
Get the platform ID of this instance
|
get |
Get the Version of this instance
|
get |
Get the Product Type of this instance
|
get |
Return true if this is a windows platform
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
get |
Return true if this is a Unix or Linux platform
Referenced by NUnit.Framework.Attributes.TestCaseAttributeTests.CanExcludePlatform(), NUnit.Framework.Attributes.TestCaseAttributeTests.CanIncludePlatform(), and NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
get |
Return true if the platform is Win32S
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
get |
Return true if the platform is Win32Windows
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
get |
Return true if the platform is Win32NT
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
get |
Return true if the platform is Windows CE
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
get |
Return true if the platform is Xbox
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
get |
Return true if the platform is MacOSX
Referenced by NUnit.Framework.Attributes.TestCaseAttributeTests.CanExcludePlatform(), NUnit.Framework.Attributes.TestCaseAttributeTests.CanIncludePlatform(), NUnit.Framework.Attributes.ApplyToTestTests.GetMyPlatform(), and NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
get |
Return true if the platform is Windows 95
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
get |
Return true if the platform is Windows 98
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
get |
Return true if the platform is Windows ME
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
get |
Return true if the platform is NT 3
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
get |
Return true if the platform is NT 4
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
get |
Return true if the platform is NT 5
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
get |
Return true if the platform is Windows 2000
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
get |
Return true if the platform is Windows XP
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
get |
Return true if the platform is Windows 2003 Server
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
get |
Return true if the platform is NT 6
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
get |
Return true if the platform is NT 6.0
|
get |
Return true if the platform is NT 6.1
|
get |
Return true if the platform is NT 6.2
|
get |
Return true if the platform is NT 6.3
|
get |
Return true if the platform is Vista
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
get |
Return true if the platform is Windows 2008 Server (original or R2)
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
get |
Return true if the platform is Windows 2008 Server (original)
|
get |
Return true if the platform is Windows 2008 Server R2
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
get |
Return true if the platform is Windows 2012 Server (original or R2)
|
get |
Return true if the platform is Windows 2012 Server (original)
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
get |
Return true if the platform is Windows 2012 Server R2
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
get |
Return true if the platform is Windows 7
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
get |
Return true if the platform is Windows 8
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
get |
Return true if the platform is Windows 8.1
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
get |
Return true if the platform is Windows 10
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
get |
Return true if the platform is Windows Server. This is named Windows Server 10 to distinguish it from previous versions of Windows Server.
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().