Early Preview

This is currently very much a preview. Please feel free to try things out, but don't be upset if anything is not yet working. Feedback is welcome over on our GitHub Dicussions page.

struct System.​Runtime.​InteropServices.​OSPlatform

Assembly: System.Runtime

Implemented Interfaces

Represents an operating system platform.

Properties

public static OSPlatform
FreeBSD
Gets an object that represents the FreeBSD operating system.
public static OSPlatform
Linux
Gets an object that represents the Linux operating system.
public static OSPlatform
OSX
Gets an object that represents the OSX operating system.
public static OSPlatform
Windows
Gets an object that represents the Windows operating system.

Methods

public static OSPlatform
Create​(string osPlatform)
Creates a new <see cref="T:System.Runtime.InteropServices.OSPlatform" /> instance.
Returns An object that represents the <paramref name="osPlatform" /> operating system.
osPlatform The name of the platform that this instance represents.
public bool
Equals​(object obj)
Determines whether the current <see cref="T:System.Runtime.InteropServices.OSPlatform" /> instance is equal to the specified object.
Returns <see langword="true" /> if <paramref name="obj" /> is a <see cref="T:System.Runtime.InteropServices.OSPlatform" /> instance and its name is the same as the current object.
obj <see langword="true" /> if <paramref name="obj" /> is a <see cref="T:System.Runtime.InteropServices.OSPlatform" /> instance and its name is the same as the current object; otherwise, <see langword="false" /> .
public bool
Equals​(OSPlatform other)
Determines whether the current instance and the specified <see cref="T:System.Runtime.InteropServices.OSPlatform" /> instance are equal.
Returns <see langword="true" /> if the current instance and <paramref name="other" /> are equal; otherwise, <see langword="false" /> .
other The object to compare with the current instance.
public int
GetHashCode​()
Returns the hash code for this instance.
Returns The hash code for this instance.
public string
ToString​()
Returns the string representation of this <see cref="T:System.Runtime.InteropServices.OSPlatform" /> instance.
Returns A string that represents this <see cref="T:System.Runtime.InteropServices.OSPlatform" /> instance.
protected void
Finalize​()
Inherited from object
Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
public Type
GetType​()
Inherited from object
Gets the <see cref="T:System.Type" /> of the current instance.
Returns The exact runtime type of the current instance.
protected object
MemberwiseClone​()
Inherited from object
Creates a shallow copy of the current <see cref="T:System.Object" /> .
Returns A shallow copy of the current <see cref="T:System.Object" /> .