Package com.ferrumx.system.hardware
Class Win32_BIOS
java.lang.Object
com.ferrumx.system.hardware.Win32_BIOS
This class contains methods that query the Win32_BIOS class of WMI and fetch
BIOS information.
Fetches the following properties and their values: Name, Caption, Manufacturer, ReleaseDate, SMBIOSPResent, Status, Version, CurrentLanguage, SMBIOSBIOSVersion
- Author:
- Egg-03
-
Method Summary
Modifier and TypeMethodDescriptionFetches Primary BIOS Information (If your motherboard has multiple BIOSes, the Main BIOS information will always be fetched).
-
Method Details
-
getPrimaryBIOS
public static Map<String,String> getPrimaryBIOS() throws IOException, IndexOutOfBoundsException, ShellException, InterruptedExceptionFetches Primary BIOS Information (If your motherboard has multiple BIOSes, the Main BIOS information will always be fetched). Internally callsCIM_ML.getPropertiesAndTheirValuesWhere(String, String, String, String)
with the parameters being (classname, "PrimaryBIOS", "True", attributes);- Returns:
- a
Map
containing the properties and their values mentioned in the class description, as key-value pairs - Throws:
IOException
- re-throws the exception thrown byCIM_ML.getPropertiesAndTheirValuesWhere(String, String, String, String)
when there are I/O Errors during streaming of data from and to Powershell and other generated filesIndexOutOfBoundsException
- re-throws the exception thrown byCIM_ML.getPropertiesAndTheirValuesWhere(String, String, String, String)
when there is a parsing error of data fetched from Windows PowershellShellException
- if any internal command used in the powershell throws errorsInterruptedException
- if the thread waiting for the process to exit, gets interrupted. When catching this exception, you may re-throw it's interrupted status by using Thread.currentThread().interrupt();
-