├── FodyWeavers.xml
├── Lib
└── OpenHardwareMonitorLib.dll
├── Properties
├── Settings.settings
├── Settings.Designer.cs
├── AssemblyInfo.cs
├── Resources.Designer.cs
└── Resources.resx
├── packages.config
├── App.xaml
├── App.xaml.cs
├── Sharp Profiler.sln
├── Hardware
├── Component.cs
├── Memory.cs
└── Processor.cs
├── .gitignore
├── app.manifest
├── Windows
├── SharpProfiler.xaml.cs
└── SharpProfiler.xaml
├── Sharp Profiler.csproj
└── LICENSE
/FodyWeavers.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/Lib/OpenHardwareMonitorLib.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aaronjwood/SharpProfiler/HEAD/Lib/OpenHardwareMonitorLib.dll
--------------------------------------------------------------------------------
/Properties/Settings.settings:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/App.xaml:
--------------------------------------------------------------------------------
1 |
5 |
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/App.xaml.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Configuration;
4 | using System.Data;
5 | using System.Linq;
6 | using System.Windows;
7 |
8 | namespace Sharp_Profiler
9 | {
10 | ///
11 | /// Interaction logic for App.xaml
12 | ///
13 | public partial class App : Application
14 | {
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/Properties/Settings.Designer.cs:
--------------------------------------------------------------------------------
1 | //------------------------------------------------------------------------------
2 | //
3 | // This code was generated by a tool.
4 | // Runtime Version:4.0.30319.225
5 | //
6 | // Changes to this file may cause incorrect behavior and will be lost if
7 | // the code is regenerated.
8 | //
9 | //------------------------------------------------------------------------------
10 |
11 | namespace Sharp_Profiler.Properties
12 | {
13 |
14 |
15 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
16 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "10.0.0.0")]
17 | internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase
18 | {
19 |
20 | private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
21 |
22 | public static Settings Default
23 | {
24 | get
25 | {
26 | return defaultInstance;
27 | }
28 | }
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/Sharp Profiler.sln:
--------------------------------------------------------------------------------
1 |
2 | Microsoft Visual Studio Solution File, Format Version 12.00
3 | # Visual Studio 14
4 | VisualStudioVersion = 14.0.23107.0
5 | MinimumVisualStudioVersion = 10.0.40219.1
6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Sharp Profiler", "Sharp Profiler.csproj", "{FD6B95FA-5110-4369-BEF4-F6CD64149AA8}"
7 | EndProject
8 | Global
9 | GlobalSection(SolutionConfigurationPlatforms) = preSolution
10 | Debug|Any CPU = Debug|Any CPU
11 | Debug|x86 = Debug|x86
12 | Release|Any CPU = Release|Any CPU
13 | Release|x86 = Release|x86
14 | EndGlobalSection
15 | GlobalSection(ProjectConfigurationPlatforms) = postSolution
16 | {FD6B95FA-5110-4369-BEF4-F6CD64149AA8}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
17 | {FD6B95FA-5110-4369-BEF4-F6CD64149AA8}.Debug|Any CPU.Build.0 = Debug|Any CPU
18 | {FD6B95FA-5110-4369-BEF4-F6CD64149AA8}.Debug|x86.ActiveCfg = Debug|x86
19 | {FD6B95FA-5110-4369-BEF4-F6CD64149AA8}.Debug|x86.Build.0 = Debug|x86
20 | {FD6B95FA-5110-4369-BEF4-F6CD64149AA8}.Release|Any CPU.ActiveCfg = Release|Any CPU
21 | {FD6B95FA-5110-4369-BEF4-F6CD64149AA8}.Release|Any CPU.Build.0 = Release|Any CPU
22 | {FD6B95FA-5110-4369-BEF4-F6CD64149AA8}.Release|x86.ActiveCfg = Release|x86
23 | {FD6B95FA-5110-4369-BEF4-F6CD64149AA8}.Release|x86.Build.0 = Release|x86
24 | EndGlobalSection
25 | GlobalSection(SolutionProperties) = preSolution
26 | HideSolutionNode = FALSE
27 | EndGlobalSection
28 | EndGlobal
29 |
--------------------------------------------------------------------------------
/Hardware/Component.cs:
--------------------------------------------------------------------------------
1 | using System.Collections.Generic;
2 | using System.Management;
3 |
4 | namespace Sharp_Profiler.Hardware
5 | {
6 | abstract class Component
7 | {
8 | ///
9 | /// Performs queries against WMI and returns an object with the specified property
10 | ///
11 | /// The WMI query
12 | /// The property that you want returned
13 | /// WMI object
14 | protected object queryWmi(string query, string property)
15 | {
16 | foreach (ManagementObject item in new ManagementObjectSearcher(query).Get())
17 | {
18 | return item[property];
19 | }
20 | return null;
21 | }
22 |
23 | ///
24 | /// Performs queries against WMI and returns a list of objects with the specified property
25 | ///
26 | /// The WMI query
27 | /// The property that you want from each item
28 | /// How many items you want returned. Specifying 0 will grab everything
29 | /// List of items with the specified property
30 | protected List