++ed by:
GBOUGARD AERO

2 PAUSE users
1 non-PAUSE user.

Guillaume Bougard

NAME

FusionInventory::Agent::Inventory - Inventory data structure

DESCRIPTION

This is a data structure corresponding to an hardware and software inventory.

METHODS

new(%params)

The constructor. The following parameters are allowed, as keys of the %params hash:

logger

a logger object

statedir

a path to a writable directory containing the last serialized inventory

tag

an arbitrary label, used for server-side filtering

getContent()

Get content attribute.

getSection($section)

Get full machine inventory section.

getField($section,$field)

Get a field from a full machine inventory section.

mergeContent($content)

Merge content to the inventory.

addEntry(%params)

Add a new entry to the inventory. The following parameters are allowed, as keys of the %params hash:

section

the entry section (mandatory)

entry

the entry (mandatory)

noDuplicated

ignore entry if already present

setTag($tag)

Set inventory tag, an arbitrary label used for filtering on server side.

getHardware($field)

Get machine global information from known machine inventory.

setHardware()

Save global information regarding the machine.

setOperatingSystem()

Operating System information.

getBios($field)

Get BIOS information from known inventory.

setBios()

Set BIOS information.

setAccessLog()

What is that for? :)

computeChecksum()

Compute the inventory checksum. This information is used by the server to know which parts of the inventory have changed since the last one.

computeLegacyValues()

Compute the inventory global values, meaning values in hardware section such as CPU number, speed and model, computed from other values, but needed for OCS compatibility.

saveLastState()

At the end of the process IF the inventory was saved correctly, the last_state is saved.

getRemote()

Method to get the parent task remote status.

Returns the string set by setRemote() API or an empty string.

setRemote([$task])

Method to set or reset the parent task remote status.

Without $task parameter, the API resets the parent remote status to an empty string.