Interface IPlatform
Platform-specific methods.
Namespace: FM.LiveSwitch
Assembly: FM.LiveSwitch.dll
Syntax
public interface IPlatform
Properties
Architecture
Gets the current CPU architecture.
Declaration
Architecture Architecture { get; }
Property Value
Type | Description |
---|---|
Architecture |
CoreCount
Gets the current CPU core count.
Declaration
int CoreCount { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
CryptoLibrary
Gets or sets the cryptography library to use.
Declaration
CryptoLibrary CryptoLibrary { get; set; }
Property Value
Type | Description |
---|---|
CryptoLibrary |
DirectorySeparator
Gets the character used to separate directories.
Declaration
string DirectorySeparator { get; }
Property Value
Type | Description |
---|---|
System.String |
IsLittleEndian
Gets a value indicating whether this is little-endian platform.
Declaration
bool IsLittleEndian { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
IsMobile
Gets or sets a value indicating whether this is a mobile platform.
Declaration
bool IsMobile { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
MachineName
Gets the current machine name.
Declaration
string MachineName { get; }
Property Value
Type | Description |
---|---|
System.String |
OperatingSystem
Gets the current operating system.
Declaration
OperatingSystem OperatingSystem { get; }
Property Value
Type | Description |
---|---|
OperatingSystem |
OperatingSystemVersion
Gets the current operating system version.
Declaration
string OperatingSystemVersion { get; }
Property Value
Type | Description |
---|---|
System.String |
PhysicalMemory
Gets the current physical memory in bytes.
Declaration
long PhysicalMemory { get; }
Property Value
Type | Description |
---|---|
System.Int64 |
PlatformTypeVersion
Gets the current version of the PlatformType being used.
Declaration
string PlatformTypeVersion { get; }
Property Value
Type | Description |
---|---|
System.String |
ProcessId
Gets the id of the current process.
Declaration
int ProcessId { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
SourceLanguage
Gets the current programming language for the source code.
Declaration
SourceLanguage SourceLanguage { get; }
Property Value
Type | Description |
---|---|
SourceLanguage |
Type
Gets the current PlatformType being used.
Declaration
PlatformType Type { get; }
Property Value
Type | Description |
---|---|
PlatformType |
UseFipsAlgorithms
Gets or sets a value that indicates whether FIPS algorithms should be used. Note that not all platforms or third-party libraries are FIPS-compliant, so this should not be used as a guarantee of FIPS compliance.
Declaration
bool UseFipsAlgorithms { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
Methods
ToString(Boolean)
Gets the string representation of the PlatformType and Platform type version, if isVerbose is true then the OS and OS version are included.
Declaration
string ToString(bool isVerbose)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | isVerbose |
Returns
Type | Description |
---|---|
System.String |