Interface IGorgonComputerInfo
Provides information about the current platform.
Namespace: Gorgon.Diagnostics
Assembly: Gorgon.Core.dll
Syntax
public interface IGorgonComputerInfo
Remarks
Ths interface will only be implemented on a platform specific assembly (e.g. Gorgon.Windows) since it requires platform specific functionality.
Properties
| Edit this page View SourceAvailablePhysicalRAM
Property to return the available physical RAM in bytes.
Declaration
long AvailablePhysicalRAM { get; }
Property Value
Type | Description |
---|---|
long |
ComputerName
Property to return the name for the computer.
Declaration
string ComputerName { get; }
Property Value
Type | Description |
---|---|
string |
MachineEnvironmentVariables
Property to return a list of machine specific environment variables.
Declaration
IReadOnlyDictionary<string, string> MachineEnvironmentVariables { get; }
Property Value
Type | Description |
---|---|
IReadOnlyDictionary<string, string> |
OperatingSystemArchitecture
Property to return the architecture of the Operating System that Gorgon is running on.
Declaration
PlatformArchitecture OperatingSystemArchitecture { get; }
Property Value
Type | Description |
---|---|
PlatformArchitecture |
Remarks
When the application that uses this class is run on a 64 bit version of windows, and on a 64 bit machine then this value will return x64, otherwise it will return x86.
OperatingSystemPlatform
Property to return the platform for the Operating System.
Declaration
PlatformID OperatingSystemPlatform { get; }
Property Value
Type | Description |
---|---|
PlatformID |
OperatingSystemServicePack
Property to return the service pack that is applied to the operating system.
Declaration
string OperatingSystemServicePack { get; }
Property Value
Type | Description |
---|---|
string |
OperatingSystemVersion
Property to return the version of the operating system.
Declaration
Version OperatingSystemVersion { get; }
Property Value
Type | Description |
---|---|
Version |
OperatingSystemVersionText
Property to return the operating system version as a formatted text string.
Declaration
string OperatingSystemVersionText { get; }
Property Value
Type | Description |
---|---|
string |
Remarks
This includes the platform, version number and service pack.
PlatformArchitecture
Property to return the platform that this instance of Gorgon was compiled for.
Declaration
PlatformArchitecture PlatformArchitecture { get; }
Property Value
Type | Description |
---|---|
PlatformArchitecture |
Remarks
When the application that uses this class is run on a 64 bit version of windows, on a 64 bit machine, and the application is running as 64 bit, then this value will return x64, otherwise it will return x86.
ProcessEnvironmentVariables
Property to return a list of process specific environment variables.
Declaration
IReadOnlyDictionary<string, string> ProcessEnvironmentVariables { get; }
Property Value
Type | Description |
---|---|
IReadOnlyDictionary<string, string> |
ProcessorCount
Property to return the number of processors in the computer.
Declaration
int ProcessorCount { get; }
Property Value
Type | Description |
---|---|
int |
SystemDirectory
Property to return the system directory for the operating system.
Declaration
string SystemDirectory { get; }
Property Value
Type | Description |
---|---|
string |
TotalPhysicalRAM
Property to return the total physical RAM available in bytes.
Declaration
long TotalPhysicalRAM { get; }
Property Value
Type | Description |
---|---|
long |
UserEnvironmentVariables
Property to return a list of user specific environment variables.
Declaration
IReadOnlyDictionary<string, string> UserEnvironmentVariables { get; }
Property Value
Type | Description |
---|---|
IReadOnlyDictionary<string, string> |
Methods
| Edit this page View SourceRefreshEnvironmentVariables()
Function to refresh the list of user and machine specific environment variables.
Declaration
void RefreshEnvironmentVariables()
Remarks
This method will populate the MachineEnvironmentVariables, ProcessEnvironmentVariables, and the UserEnvironmentVariables properties with values from the environment variables for the operating system. These values cannot be modified from this class since this class is meant for information gathering only.