InfHelper 0.6.6
There is a newer version of this package available.
See the version list below for details.
See the version list below for details.
dotnet add package InfHelper --version 0.6.6
NuGet\Install-Package InfHelper -Version 0.6.6
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="InfHelper" Version="0.6.6" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add InfHelper --version 0.6.6
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: InfHelper, 0.6.6"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install InfHelper as a Cake Addin
#addin nuget:?package=InfHelper&version=0.6.6
// Install InfHelper as a Cake Tool
#tool nuget:?package=InfHelper&version=0.6.6
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
InfHelper
- Nuget package for C# that makes it easy to parse .inf files, to store and work with information about system drivers.
- This NuGet Package allows you to parse .inf files and browse them using object model wrappers (using the InfData class). You can browse categories and their keys by handling them as collections or simply using [id] operators. Currently, this package does not support installing drivers from inf files, only parsing and browsing through the file. The feature for creating an INF file will be added in later versions.
How to use
Init parsing
var helper = new InfUtil();
var data = helper.ParseFile(path);
Getting data
//obtain category by id
var version = data["Version"];
//get keys from the category
var providerKey = version["Provider"];
var classGuidKey = version["ClassGuid"];
//obtain key directely
var key = data["Strings"]["KeyId"];
// get list of vaues separated by comma
var values = key.KeyValues;
//get value
var value = values[0].Value;
if(value.IsDynamic){
//the key value refers to another key
}
//you can also ignore all wrappers and just get the primitive value (string)
var value = key.PrimitiveValue;
Custom driver info serialization
public class DriverInfo
{
[InfKeyValue("Version","Class")]
public string Class { get; set; }
[InfKeyValue("Version", "Provider")]
public string Provider { get; set; }
}
// ....
var helper = new InfUtil();
var serilized = helper.SerializeFileInto<DriverInfo>(Path.Combine(testFolder,
"oem100.inf" out InfData data);
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET Framework | net is compatible. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
This package has no dependencies.
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last updated |
---|---|---|
0.12.1 | 199 | 1/25/2024 |
0.11.3 | 153 | 12/26/2023 |
0.11.2 | 95 | 12/26/2023 |
0.11.1 | 102 | 12/23/2023 |
0.10.1 | 108 | 12/4/2023 |
0.9.1 | 115 | 9/17/2023 |
0.8.1 | 187 | 7/24/2023 |
0.7.1 | 300 | 1/11/2023 |
0.6.6 | 30,768 | 9/10/2017 |
0.6.5 | 859 | 9/5/2017 |
0.6.0 | 861 | 9/5/2017 |
0.5.4 | 858 | 8/30/2017 |
0.5.3 | 873 | 8/29/2017 |
0.5.2 | 880 | 8/29/2017 |
0.5.1 | 947 | 8/28/2017 |
0.5.0 | 902 | 8/28/2017 |
This is a beta version, some features were not yet implemented or tested.
Added case insensitivity.
Can search key id across all categories.
Can serialize driver information into custom model, using custom Attribute.
Can dereference simple dynamic value keys while serializing.