Skip to content
This repository has been archived by the owner on Jan 23, 2023. It is now read-only.
/ corefx Public archive

Commit

Permalink
Add System.Management (#24719)
Browse files Browse the repository at this point in the history
* First pass building

* Remove Instrumentation and WMIGenerator

* Resources to as used on CoreFX

Opportunistic: some small changes related to warnings

* Removed hard coded path to load wminet_utils

Also moved so DllImport to use Common version of files.

* Added ref, sln, and single basic test

Code builds and pass single test

* Add CoreFX source header

* Removing unused using directives

* clean src proj references

* A bit more test coverage (19%)

* Sanitizer pass with default settings

* Adding WMIGenerator

This allows methods to generate CodeDom for strong type access to WMI
objects.

* Missing files from previous commit

* Some extra clean-up missed by SSS

* Removing #ifdef dead code

* Add pkg project

* Removing more dead code

* Removing dead code and small improvement to tests

* Suppress CA1821 when generating PNSE assembly

The finalizers are being generated empty for PNSE assembly. In such
cases disable CA1821.

* Source changes from CR (so far)

* Targets and package issues

* Go back to project targets and settings

Per conversation w/ @weshaggard it should follow the same model as
System.DirectoryServices not the packages of dlls that do not exist on
desktop. This still is not expected to be fully correct but it puts the
projects closer to the targets that they will have in the end.

* Description for the System.Management package.

* Match supported pkg frameworks

* Skip tests on Windows Nano

* Missed files from previous commit

* Untabify files and a bit more tests

* Generate PNS Assembly for uap

* Add references needed by uap for PNS assembly

* PNS assembly message

* Fixing package issue
  • Loading branch information
Paulo Janotti authored Oct 25, 2017
1 parent f5db8f7 commit 0f57714
Show file tree
Hide file tree
Showing 42 changed files with 31,960 additions and 0 deletions.
3 changes: 3 additions & 0 deletions pkg/Microsoft.Private.PackageBaseline/packageIndex.json
Original file line number Diff line number Diff line change
Expand Up @@ -2342,6 +2342,9 @@
"System.Management": {
"InboxOn": {
"net45": "4.0.0.0"
},
"AssemblyVersionInPackageVersion": {
"4.0.0.0": "4.5.0"
}
},
"System.Management.Instrumentation": {
Expand Down
9 changes: 9 additions & 0 deletions pkg/descriptions.json
Original file line number Diff line number Diff line change
Expand Up @@ -947,6 +947,15 @@
"System.Linq.EnumerableQuery"
]
},
{
"Name": "System.Management",
"Description": "Provides access to a rich set of management information and management events about the system, devices, and applications instrumented to the Windows Management Instrumentation (WMI) infrastructure.",
"CommonTypes": [
"System.Management.ManagementClass",
"System.Management.ManagementObject",
"System.Management.SelectQuery"
]
},
{
"Name": "System.Memory",
"Description": "Provides types for efficient low-allocation access to memory.",
Expand Down
50 changes: 50 additions & 0 deletions src/System.Management/System.Management.sln
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 14
VisualStudioVersion = 14.0.25420.1
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "System.Management.Tests", "tests\System.Management.Tests.csproj", "{5456707C-489E-4562-846E-B9598569F6BE}"
ProjectSection(ProjectDependencies) = postProject
{950923D8-EC99-4F90-9BA6-8EB64582C555} = {950923D8-EC99-4F90-9BA6-8EB64582C555}
EndProjectSection
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "System.Management", "src\System.Management.csproj", "{950923D8-EC99-4F90-9BA6-8EB64582C555}"
ProjectSection(ProjectDependencies) = postProject
{CA17270B-079F-4D52-97E8-C0C2E8B9D7DB} = {CA17270B-079F-4D52-97E8-C0C2E8B9D7DB}
EndProjectSection
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "System.Management", "ref\System.Management.csproj", "{CA17270B-079F-4D52-97E8-C0C2E8B9D7DB}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "tests", "tests", "{1A2F9F4A-A032-433E-B914-ADD5992BB178}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{E107E9C1-E893-4E87-987E-04EF0DCEAEFD}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "ref", "ref", "{2E666815-2EDB-464B-9DF6-380BF4789AD4}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{5456707C-489E-4562-846E-B9598569F6BE}.Debug|Any CPU.ActiveCfg = netcoreapp-Windows_NT-Debug|Any CPU
{5456707C-489E-4562-846E-B9598569F6BE}.Debug|Any CPU.Build.0 = netcoreapp-Windows_NT-Debug|Any CPU
{5456707C-489E-4562-846E-B9598569F6BE}.Release|Any CPU.ActiveCfg = netcoreapp-Windows_NT-Release|Any CPU
{5456707C-489E-4562-846E-B9598569F6BE}.Release|Any CPU.Build.0 = netcoreapp-Windows_NT-Release|Any CPU
{950923D8-EC99-4F90-9BA6-8EB64582C555}.Debug|Any CPU.ActiveCfg = netstandard-Windows_NT-Debug|Any CPU
{950923D8-EC99-4F90-9BA6-8EB64582C555}.Debug|Any CPU.Build.0 = netstandard-Windows_NT-Debug|Any CPU
{950923D8-EC99-4F90-9BA6-8EB64582C555}.Release|Any CPU.ActiveCfg = netstandard-Windows_NT-Release|Any CPU
{950923D8-EC99-4F90-9BA6-8EB64582C555}.Release|Any CPU.Build.0 = netstandard-Windows_NT-Release|Any CPU
{CA17270B-079F-4D52-97E8-C0C2E8B9D7DB}.Debug|Any CPU.ActiveCfg = netstandard-Debug|Any CPU
{CA17270B-079F-4D52-97E8-C0C2E8B9D7DB}.Debug|Any CPU.Build.0 = netstandard-Debug|Any CPU
{CA17270B-079F-4D52-97E8-C0C2E8B9D7DB}.Release|Any CPU.ActiveCfg = netstandard-Release|Any CPU
{CA17270B-079F-4D52-97E8-C0C2E8B9D7DB}.Release|Any CPU.Build.0 = netstandard-Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(NestedProjects) = preSolution
{5456707C-489E-4562-846E-B9598569F6BE} = {1A2F9F4A-A032-433E-B914-ADD5992BB178}
{950923D8-EC99-4F90-9BA6-8EB64582C555} = {E107E9C1-E893-4E87-987E-04EF0DCEAEFD}
{CA17270B-079F-4D52-97E8-C0C2E8B9D7DB} = {2E666815-2EDB-464B-9DF6-380BF4789AD4}
EndGlobalSection
EndGlobal
11 changes: 11 additions & 0 deletions src/System.Management/dir.props
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="14.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="..\dir.props" />
<PropertyGroup>
<!-- this assembly is inbox in desktop, do not version it unless you
plan on shipping a new desktop version out of band. Instead add API
to a different assembly. -->
<AssemblyVersion>4.0.0.0</AssemblyVersion>
<AssemblyKey>MSFT</AssemblyKey>
</PropertyGroup>
</Project>
17 changes: 17 additions & 0 deletions src/System.Management/pkg/System.Management.pkgproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="14.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), dir.props))\dir.props" />
<ItemGroup>
<ProjectReference Include="..\ref\System.Management.csproj">
<SupportedFramework>netcoreapp2.0;net45;$(UAPvNextTFM);$(AllXamarinFrameworks)</SupportedFramework>
</ProjectReference>
<ProjectReference Include="..\src\System.Management.csproj" />
<InboxOnTargetFramework Include="net45">
<AsFrameworkReference>true</AsFrameworkReference>
</InboxOnTargetFramework>
<File Include="$(PlaceHolderFile)">
<TargetPath>runtimes/win/lib/net45</TargetPath>
</File>
</ItemGroup>
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), dir.targets))\dir.targets" />
</Project>
8 changes: 8 additions & 0 deletions src/System.Management/ref/Configurations.props
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="14.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<BuildConfigurations>
netstandard;
</BuildConfigurations>
</PropertyGroup>
</Project>
Loading

0 comments on commit 0f57714

Please sign in to comment.