diff --git a/CHANGELOG.md b/CHANGELOG.md index 3778787..7f77909 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,14 +1,14 @@ # Changelog All notable changes to this project will be documented in this file. -## 1.0.8 - +## [1.0.8] - 2019-08-23 ### Added - Added **iTin.Core.Hardware.Specification.Smbios** project for **SMBIOS** calls. - - Implements the full specification. + - Implements the fully specification(s). - - Now you can directly access the Smbios properties, to do this make the following call. + - Now you can directly access the SMBIOS properties, to do this make the following call. var smbios = SMBIOS.Instance.ImplementedStructures; @@ -26,10 +26,10 @@ All notable changes to this project will be documented in this file. · Dmi will have one property available: > DmiProperty.Bios.BiosRomSize - - Added **iTin.Core.Hardware.Specification.Tpm** project. - Includes TPM (Trusted Platform Module), used in SmbiosType043 [TPM Device] class. + - Minor changes. ### Changed @@ -49,6 +49,8 @@ All notable changes to this project will be documented in this file. - test - iSMBIOS.ConsoleApp [Console Test App] +- Assemblies with strong naming. + ### Removed - Unused variables. diff --git a/README.md b/README.md index b528d1b..cb99ae7 100644 --- a/README.md +++ b/README.md @@ -84,11 +84,19 @@ Call **DMI.Instance.Structures** for getting all SMBIOS structures availables. // Requires that the Slot Information structure exists in your system DmiStructureCollection structures = DMI.Instance.Structures; IDictionary systemSlots = structures.GetProperties(DmiProperty.SystemSlots.SlotId); - foreach (KeyValuePair systemSlot in systemSlots) + bool hasSystemSlots = systemSlots.Any(); + if (!hasSystemSlots) { - int element = systemSlot.Key; - object property = systemSlot.Value; - Console.WriteLine($" System Slot ({element}) > {property}"); + Console.WriteLine($" > There is no system slots information structure in this computer"); + } + else + { + foreach (KeyValuePair systemSlot in systemSlots) + { + int element = systemSlot.Key; + object property = systemSlot.Value; + Console.WriteLine($" System Slot ({element}) > {property}"); + } } 5. Prints all **SMBIOS** structures properties @@ -181,10 +189,10 @@ Call **DMI.Instance.Structures** for getting all SMBIOS structures availables. private static string GetFriendlyName(IPropertyKey value) { - string friendlyName = value.GetPropertyName(); - return string.IsNullOrEmpty(friendlyName) + string name = value.GetPropertyName(); + return string.IsNullOrEmpty(name) ? value.PropertyId.ToString() - : friendlyName; + : name; } # How can I send feedback!!! diff --git a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Dmi/DMI.cs b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Dmi/DMI.cs index 9c833ef..f15b2ed 100644 --- a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Dmi/DMI.cs +++ b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Dmi/DMI.cs @@ -6,8 +6,8 @@ namespace iTin.Core.Hardware.Specification using Dmi; /// - /// The Desktop Management Interface (DMI) ó La interfaz de administración de escritorio, marco estándar para la gestión y - /// seguimiento de componentes en un ordenador de sobremesa, portátil o servidor. + /// The Desktop Management Interface (DMI) or the desktop management interface, standard framework for management and + /// component tracking on a desktop, laptop or server. /// public sealed class DMI { diff --git a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Dmi/Properties/AssemblyInfo.cs b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Dmi/Properties/AssemblyInfo.cs index 76f389a..db4a817 100644 --- a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Dmi/Properties/AssemblyInfo.cs +++ b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Dmi/Properties/AssemblyInfo.cs @@ -6,11 +6,11 @@ // conjunto de atributos. Cambie estos valores de atributo para modificar la información // asociada con un ensamblado. [assembly: AssemblyTitle("iTin.Core.Hardware.Specification.Dmi")] -[assembly: AssemblyDescription("")] +[assembly: AssemblyDescription("The Desktop Management Interface (DMI) or the desktop management interface, standard framework for management and component tracking on a desktop, laptop or server.")] [assembly: AssemblyConfiguration("")] -[assembly: AssemblyCompany("")] +[assembly: AssemblyCompany("iTin")] [assembly: AssemblyProduct("iTin.Core.Hardware.Specification.Dmi")] -[assembly: AssemblyCopyright("Copyright © 2019")] +[assembly: AssemblyCopyright("Copyright © 2018")] [assembly: AssemblyTrademark("")] [assembly: AssemblyCulture("")] diff --git a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Dmi/iTin.Core.Hardware.Specification.Dmi.csproj b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Dmi/iTin.Core.Hardware.Specification.Dmi.csproj index 670fa6b..d060fa0 100644 --- a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Dmi/iTin.Core.Hardware.Specification.Dmi.csproj +++ b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Dmi/iTin.Core.Hardware.Specification.Dmi.csproj @@ -30,6 +30,12 @@ prompt 4 + + true + + + key.snk + @@ -136,5 +142,8 @@ iTin.Core.Hardware.Specification.Tpm + + + \ No newline at end of file diff --git a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Dmi/key.snk b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Dmi/key.snk new file mode 100644 index 0000000..58bf4e9 Binary files /dev/null and b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Dmi/key.snk differ diff --git a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/Properties/AssemblyInfo.cs b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/Properties/AssemblyInfo.cs index c5fa6cf..b6347b7 100644 --- a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/Properties/AssemblyInfo.cs +++ b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/Properties/AssemblyInfo.cs @@ -5,11 +5,11 @@ // La información general de un ensamblado se controla mediante el siguiente // conjunto de atributos. Cambie estos valores de atributo para modificar la información // asociada con un ensamblado. -[assembly: AssemblyTitle("iDMI")] -[assembly: AssemblyDescription("iDMI is a lightweight implementation that allows us to obtain the SMBIOS information")] +[assembly: AssemblyTitle("iTin.Core.Hardware.Specification.Smbios")] +[assembly: AssemblyDescription("System Management BIOS (SMBIOS). Standard format of the data collected by the BIOS. SMBIOS defines this information in a series of data tables, where information about system components such as memory, peripheral devices, expansion cards, inventory label and operating system is collected.")] [assembly: AssemblyConfiguration("")] [assembly: AssemblyCompany("iTin")] -[assembly: AssemblyProduct("iDMI")] +[assembly: AssemblyProduct("iTin.Core.Hardware.Specification.Smbios")] [assembly: AssemblyCopyright("Copyright © 2018")] [assembly: AssemblyTrademark("")] [assembly: AssemblyCulture("")] @@ -32,7 +32,7 @@ // Puede especificar todos los valores o usar los números de compilación y de revisión predeterminados // mediante el carácter "*", como se muestra a continuación: // [assembly: AssemblyVersion("1.0.*")] -[assembly: AssemblyVersion("1.0.1.0")] -[assembly: AssemblyFileVersion("1.0.1.0")] +[assembly: AssemblyVersion("1.0.0.0")] +[assembly: AssemblyFileVersion("1.0.0.0")] -[assembly: InternalsVisibleTo("iTin.Core.Hardware.Specification.Dmi")] +[assembly: InternalsVisibleTo("iTin.Core.Hardware.Specification.Dmi, PublicKey=0024000004800000940000000602000000240000525341310004000001000100e1468972d9d038975693cc6a7e2669eb61e1868495ec1a034b878ff5d19a47b4878c8a98f0cf4b8d0f051df92f9d992d2a239fb00bd6e595800c66becd37f893c75f9f6de2301aa855a5a7e9590025f3bfb1a4c67311ba5d854498fd99ec0bc0672e4224321dd0995a5a43cf9f1d3846da0dae6b9a70b878345277127bf529d6")] \ No newline at end of file diff --git a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/SMBIOS/Structures/SmbiosType003 [System Enclosure or Chassis].cs b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/SMBIOS/Structures/SmbiosType003 [System Enclosure or Chassis].cs index b688e1c..3842f5f 100644 --- a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/SMBIOS/Structures/SmbiosType003 [System Enclosure or Chassis].cs +++ b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/SMBIOS/Structures/SmbiosType003 [System Enclosure or Chassis].cs @@ -100,7 +100,7 @@ namespace iTin.Core.Hardware.Specification.Smbios /// /// Specialization of the class that contains the logic to decode the System Enclosure or Chassis (Type 3) structure. /// - sealed class SmbiosType003 : SmbiosBaseType + internal sealed class SmbiosType003 : SmbiosBaseType { #region constructor/s diff --git a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/SMBIOS/Structures/SmbiosType004 [Processor Information].cs b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/SMBIOS/Structures/SmbiosType004 [Processor Information].cs index eb9ea07..b1bfa30 100644 --- a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/SMBIOS/Structures/SmbiosType004 [Processor Information].cs +++ b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/SMBIOS/Structures/SmbiosType004 [Processor Information].cs @@ -162,7 +162,7 @@ namespace iTin.Core.Hardware.Specification.Smbios /// /// Specialization of the class that contains the logic to decode the Processor Information (Type 4) structure. /// - sealed class SmbiosType004 : SmbiosBaseType + internal sealed class SmbiosType004 : SmbiosBaseType { #region constructor/s diff --git a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/SMBIOS/Structures/SmbiosType005 [Memory Controller Information (Type 5, Obsolete)].cs b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/SMBIOS/Structures/SmbiosType005 [Memory Controller Information (Type 5, Obsolete)].cs index dcaf306..fd5f411 100644 --- a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/SMBIOS/Structures/SmbiosType005 [Memory Controller Information (Type 5, Obsolete)].cs +++ b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/SMBIOS/Structures/SmbiosType005 [Memory Controller Information (Type 5, Obsolete)].cs @@ -80,7 +80,7 @@ namespace iTin.Core.Hardware.Specification.Smbios /// /// Specialization of the class that contains the logic to decode the Memory Controller Information (Type 5, Obsolete) structure. /// - sealed class SmbiosType005 : SmbiosBaseType + internal sealed class SmbiosType005 : SmbiosBaseType { #region constructor/s diff --git a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/SMBIOS/Structures/SmbiosType018 [32-Bit Memory Error Information].cs b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/SMBIOS/Structures/SmbiosType018 [32-Bit Memory Error Information].cs index 46b76a6..94d1368 100644 --- a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/SMBIOS/Structures/SmbiosType018 [32-Bit Memory Error Information].cs +++ b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/SMBIOS/Structures/SmbiosType018 [32-Bit Memory Error Information].cs @@ -63,7 +63,7 @@ namespace iTin.Core.Hardware.Specification.Smbios /// /// Specialization of the class that contains the logic to decode the 32-Bit Memory Error Information (Type 18) structure. /// - class SmbiosType018 : SmbiosBaseType + internal class SmbiosType018 : SmbiosBaseType { #region constructor/s diff --git a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/SMBIOS/Structures/SmbiosType034 [Management Device].cs b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/SMBIOS/Structures/SmbiosType034 [Management Device].cs index 263fced..1935303 100644 --- a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/SMBIOS/Structures/SmbiosType034 [Management Device].cs +++ b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/SMBIOS/Structures/SmbiosType034 [Management Device].cs @@ -36,7 +36,7 @@ namespace iTin.Core.Hardware.Specification.Smbios /// /// Specialization of the class that contains the logic to decode the Management Device (Type 34) structure. /// - sealed class SmbiosType034 : SmbiosBaseType + internal sealed class SmbiosType034 : SmbiosBaseType { #region Constructor/es diff --git a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/iTin.Core.Hardware.Specification.Smbios.csproj b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/iTin.Core.Hardware.Specification.Smbios.csproj index 3dccda2..0640560 100644 --- a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/iTin.Core.Hardware.Specification.Smbios.csproj +++ b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/iTin.Core.Hardware.Specification.Smbios.csproj @@ -34,6 +34,12 @@ 4 false + + true + + + key.snk + @@ -125,6 +131,7 @@ + diff --git a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/key.snk b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/key.snk new file mode 100644 index 0000000..90b58aa Binary files /dev/null and b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Smbios/key.snk differ diff --git a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Tpm/Properties/AssemblyInfo.cs b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Tpm/Properties/AssemblyInfo.cs index c5fa6cf..c24b5d7 100644 --- a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Tpm/Properties/AssemblyInfo.cs +++ b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Tpm/Properties/AssemblyInfo.cs @@ -5,11 +5,11 @@ // La información general de un ensamblado se controla mediante el siguiente // conjunto de atributos. Cambie estos valores de atributo para modificar la información // asociada con un ensamblado. -[assembly: AssemblyTitle("iDMI")] -[assembly: AssemblyDescription("iDMI is a lightweight implementation that allows us to obtain the SMBIOS information")] +[assembly: AssemblyTitle("iTin.Core.Hardware.Specification.Tpm")] +[assembly: AssemblyDescription("Includes TPM (Trusted Platform Module)")] [assembly: AssemblyConfiguration("")] [assembly: AssemblyCompany("iTin")] -[assembly: AssemblyProduct("iDMI")] +[assembly: AssemblyProduct("iTin.Core.Hardware.Specification.Tpm")] [assembly: AssemblyCopyright("Copyright © 2018")] [assembly: AssemblyTrademark("")] [assembly: AssemblyCulture("")] @@ -32,7 +32,16 @@ // Puede especificar todos los valores o usar los números de compilación y de revisión predeterminados // mediante el carácter "*", como se muestra a continuación: // [assembly: AssemblyVersion("1.0.*")] -[assembly: AssemblyVersion("1.0.1.0")] -[assembly: AssemblyFileVersion("1.0.1.0")] +[assembly: AssemblyVersion("1.0.0.0")] +[assembly: AssemblyFileVersion("1.0.0.0")] -[assembly: InternalsVisibleTo("iTin.Core.Hardware.Specification.Dmi")] +[assembly: InternalsVisibleTo("iTin.Core.Hardware.Specification.Dmi, PublicKey = 002400000480000094" + + "0000000602000000240000525341310004000" + + "001000100bf8c25fcd44838d87e245ab35bf7" + + "3ba2615707feea295709559b3de903fb95a93" + + "3d2729967c3184a97d7b84c7547cd87e435b5" + + "6bdf8621bcb62b59c00c88bd83aa62c4fcdd4" + + "712da72eec2533dc00f8529c3a0bbb4103282" + + "f0d894d5f34e9f0103c473dce9f4b457a5dee" + + "fd8f920d8681ed6dfcb0a81e96bd9b176525a" + + "26e0b3")] diff --git a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Tpm/iTin.Core.Hardware.Specification.Tpm.csproj b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Tpm/iTin.Core.Hardware.Specification.Tpm.csproj index b08c68e..3a63818 100644 --- a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Tpm/iTin.Core.Hardware.Specification.Tpm.csproj +++ b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Tpm/iTin.Core.Hardware.Specification.Tpm.csproj @@ -34,6 +34,12 @@ 4 false + + true + + + key.snk + @@ -49,6 +55,7 @@ + diff --git a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Tpm/key.snk b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Tpm/key.snk new file mode 100644 index 0000000..c4b654e Binary files /dev/null and b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware.Specification/iTin.Core.Hardware.Specification.Tpm/key.snk differ diff --git a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware/Properties/AssemblyInfo.cs b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware/Properties/AssemblyInfo.cs index 90f04bd..b73569d 100644 --- a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware/Properties/AssemblyInfo.cs +++ b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware/Properties/AssemblyInfo.cs @@ -6,11 +6,11 @@ // conjunto de atributos. Cambie estos valores de atributo para modificar la información // asociada con un ensamblado. [assembly: AssemblyTitle("iTin.Core.Hardware")] -[assembly: AssemblyDescription("")] +[assembly: AssemblyDescription("Hardware Interop Calls")] [assembly: AssemblyConfiguration("")] -[assembly: AssemblyCompany("")] +[assembly: AssemblyCompany("iTin")] [assembly: AssemblyProduct("iTin.Core.Hardware")] -[assembly: AssemblyCopyright("Copyright © 2019")] +[assembly: AssemblyCopyright("Copyright © 2019")] [assembly: AssemblyTrademark("")] [assembly: AssemblyCulture("")] diff --git a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware/iTin.Core.Hardware.csproj b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware/iTin.Core.Hardware.csproj index 79b072c..3984d76 100644 --- a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware/iTin.Core.Hardware.csproj +++ b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware/iTin.Core.Hardware.csproj @@ -32,6 +32,12 @@ 4 true + + true + + + key.snk + @@ -61,5 +67,8 @@ iTin.Core + + + \ No newline at end of file diff --git a/src/lib/iTin.Core.Hardware/iTin.Core.Hardware/key.snk b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware/key.snk new file mode 100644 index 0000000..6b7bb39 Binary files /dev/null and b/src/lib/iTin.Core.Hardware/iTin.Core.Hardware/key.snk differ diff --git a/src/lib/iTin.Core/iTin.Core.Interop/Properties/AssemblyInfo.cs b/src/lib/iTin.Core/iTin.Core.Interop/Properties/AssemblyInfo.cs index cb8649e..5c5bafb 100644 --- a/src/lib/iTin.Core/iTin.Core.Interop/Properties/AssemblyInfo.cs +++ b/src/lib/iTin.Core/iTin.Core.Interop/Properties/AssemblyInfo.cs @@ -6,11 +6,11 @@ // conjunto de atributos. Cambie estos valores de atributo para modificar la información // asociada con un ensamblado. [assembly: AssemblyTitle("iTin.Core.Interop")] -[assembly: AssemblyDescription("")] +[assembly: AssemblyDescription("Generic Win32 Interop Calls")] [assembly: AssemblyConfiguration("")] [assembly: AssemblyCompany("iTin")] [assembly: AssemblyProduct("iTin.Core.Interop")] -[assembly: AssemblyCopyright("Copyright © 2017")] +[assembly: AssemblyCopyright("Copyright © 2017")] [assembly: AssemblyTrademark("")] [assembly: AssemblyCulture("")] diff --git a/src/lib/iTin.Core/iTin.Core.Interop/iTin.Core.Interop.csproj b/src/lib/iTin.Core/iTin.Core.Interop/iTin.Core.Interop.csproj index 7b0c816..ad6d1a2 100644 --- a/src/lib/iTin.Core/iTin.Core.Interop/iTin.Core.Interop.csproj +++ b/src/lib/iTin.Core/iTin.Core.Interop/iTin.Core.Interop.csproj @@ -35,6 +35,12 @@ false true + + true + + + key.snk + @@ -87,7 +93,9 @@ iTin.Core - + + + diff --git a/src/lib/iTin.Core/iTin.Core.Interop/key.snk b/src/lib/iTin.Core/iTin.Core.Interop/key.snk new file mode 100644 index 0000000..4b6c160 Binary files /dev/null and b/src/lib/iTin.Core/iTin.Core.Interop/key.snk differ diff --git a/src/lib/iTin.Core/iTin.Core/Properties/AssemblyInfo.cs b/src/lib/iTin.Core/iTin.Core/Properties/AssemblyInfo.cs index 301691a..1a6a495 100644 --- a/src/lib/iTin.Core/iTin.Core/Properties/AssemblyInfo.cs +++ b/src/lib/iTin.Core/iTin.Core/Properties/AssemblyInfo.cs @@ -10,7 +10,7 @@ [assembly: AssemblyConfiguration("")] [assembly: AssemblyCompany("iTin")] [assembly: AssemblyProduct("iTin.Core")] -[assembly: AssemblyCopyright("Copyright © 2017")] +[assembly: AssemblyCopyright("Copyright © 2017")] [assembly: AssemblyTrademark("iTin")] [assembly: AssemblyCulture("")] @@ -32,5 +32,5 @@ // Puede especificar todos los valores o usar los números de compilación y de revisión predeterminados // mediante el carácter "*", como se muestra a continuación: // [assembly: AssemblyVersion("1.0.*")] -[assembly: AssemblyVersion("1.0.1.0")] -[assembly: AssemblyFileVersion("1.0.1.0")] +[assembly: AssemblyVersion("1.0.0.0")] +[assembly: AssemblyFileVersion("1.0.0.0")] diff --git a/src/lib/iTin.Core/iTin.Core/iTin.Core.csproj b/src/lib/iTin.Core/iTin.Core/iTin.Core.csproj index b2f5fc1..a9490d2 100644 --- a/src/lib/iTin.Core/iTin.Core/iTin.Core.csproj +++ b/src/lib/iTin.Core/iTin.Core/iTin.Core.csproj @@ -31,6 +31,12 @@ prompt 4 + + true + + + key.snk + @@ -81,7 +87,9 @@ Exception.Designer.cs - + + + diff --git a/src/lib/iTin.Core/iTin.Core/key.snk b/src/lib/iTin.Core/iTin.Core/key.snk new file mode 100644 index 0000000..e6b80c0 Binary files /dev/null and b/src/lib/iTin.Core/iTin.Core/key.snk differ diff --git a/src/test/iSMBIOS.ConsoleApp/Program.cs b/src/test/iSMBIOS.ConsoleApp/Program.cs index 2cc69df..a080c50 100644 --- a/src/test/iSMBIOS.ConsoleApp/Program.cs +++ b/src/test/iSMBIOS.ConsoleApp/Program.cs @@ -4,6 +4,7 @@ namespace iSMBIOS.ConsoleApp using System; using System.Collections.Generic; using System.Collections.ObjectModel; + using System.Linq; using iTin.Core.Hardware; using iTin.Core.Hardware.Specification; @@ -133,11 +134,19 @@ static void Main(string[] args) Console.WriteLine(@" Gets a multiple properties directly"); Console.WriteLine(@" ——————————————————————————————————————————————————————————————"); IDictionary systemSlots = structures.GetProperties(DmiProperty.SystemSlots.SlotId); - foreach (KeyValuePair systemSlot in systemSlots) + bool hasSystemSlots = systemSlots.Any(); + if (!hasSystemSlots) { - int element = systemSlot.Key; - object property = systemSlot.Value; - Console.WriteLine($" > System Slot ({element}) > {property}"); + Console.WriteLine($" > There is no system slots information structure in this computer"); + } + else + { + foreach (KeyValuePair systemSlot in systemSlots) + { + int element = systemSlot.Key; + object property = systemSlot.Value; + Console.WriteLine($" > System Slot ({element}) > {property}"); + } } Console.ReadLine(); @@ -145,11 +154,11 @@ static void Main(string[] args) private static string GetFriendlyName(IPropertyKey value) { - string friendlyName = value.GetPropertyName(); + string name = value.GetPropertyName(); - return string.IsNullOrEmpty(friendlyName) + return string.IsNullOrEmpty(name) ? value.PropertyId.ToString() - : friendlyName; + : name; } } } diff --git a/src/test/iSMBIOS.ConsoleApp/Properties/AssemblyInfo.cs b/src/test/iSMBIOS.ConsoleApp/Properties/AssemblyInfo.cs index cefec2e..9d7fa09 100644 --- a/src/test/iSMBIOS.ConsoleApp/Properties/AssemblyInfo.cs +++ b/src/test/iSMBIOS.ConsoleApp/Properties/AssemblyInfo.cs @@ -5,12 +5,12 @@ // La información general de un ensamblado se controla mediante el siguiente // conjunto de atributos. Cambie estos valores de atributo para modificar la información // asociada con un ensamblado. -[assembly: AssemblyTitle("iTin.Core.Hardware.ConsoleApp")] -[assembly: AssemblyDescription("")] +[assembly: AssemblyTitle("iSMBIOS.ConsoleApp")] +[assembly: AssemblyDescription("SMBIOS Console Test App")] [assembly: AssemblyConfiguration("")] -[assembly: AssemblyCompany("")] -[assembly: AssemblyProduct("iTin.Core.Hardware.ConsoleApp")] -[assembly: AssemblyCopyright("Copyright © 2017")] +[assembly: AssemblyCompany("iTin")] +[assembly: AssemblyProduct("iSMBIOS.ConsoleApp")] +[assembly: AssemblyCopyright("Copyright © 2017")] [assembly: AssemblyTrademark("")] [assembly: AssemblyCulture("")] @@ -32,5 +32,5 @@ // Puede especificar todos los valores o usar los números de compilación y de revisión predeterminados // mediante el carácter "*", como se muestra a continuación: // [assembly: AssemblyVersion("1.0.*")] -[assembly: AssemblyVersion("1.0.1.0")] -[assembly: AssemblyFileVersion("1.0.1.0")] +[assembly: AssemblyVersion("1.0.0.0")] +[assembly: AssemblyFileVersion("1.0.0.0")] diff --git a/src/test/iSMBIOS.ConsoleApp/iSMBIOS.ConsoleApp.csproj b/src/test/iSMBIOS.ConsoleApp/iSMBIOS.ConsoleApp.csproj index b76311c..c233b91 100644 --- a/src/test/iSMBIOS.ConsoleApp/iSMBIOS.ConsoleApp.csproj +++ b/src/test/iSMBIOS.ConsoleApp/iSMBIOS.ConsoleApp.csproj @@ -50,6 +50,12 @@ + + true + + + key.snk + @@ -68,6 +74,7 @@ + diff --git a/src/test/iSMBIOS.ConsoleApp/key.snk b/src/test/iSMBIOS.ConsoleApp/key.snk new file mode 100644 index 0000000..48960b4 Binary files /dev/null and b/src/test/iSMBIOS.ConsoleApp/key.snk differ