Hello World Creation

The next part of our example contains these calls:

SysInfoCore2 sysInfo = null;
SysInfo si = new SysInfo();

Line 1 creates a SysInfoCore2 variable named sysInfo. The SysInfoCore2 class is the parent object for each of SysInfo's data class objects. This variable will later be assigned to the parent object containing the data class objects.

Line 2 creates a new SysInfo object. Since no arguments are given to SysInfo() the API will look for the SysInfo runtime product in the default location of /opt/sysinfo on Linux/Unix/Mac and C:\Program Files\MagniComp\SysInfo on Windows. If the SysInfo runtime product is not found a SysInfoException will be thrown. Later sections will discuss the multiple means of specifing the location of the SysInfo runtime product.