hwdet::RPMPackager Class Reference

Adapter for the RPM command. More...

#include <RPMPackager.h>

Inheritance diagram for hwdet::RPMPackager:

hwdet::Packager hwdet::MessageReporter

Public Member Functions

 RPMPackager (MessageReporter *parent_reporter)
 Create new packager.
virtual ~RPMPackager (void)
 Free used resources.
virtual bool IsSupported (void)
 Is packager supported?
virtual bool DetectSoftware (XMLElement *products)
 Query data from package manager.

Private Attributes

bool is_supported
 Is packager supported?

Data Structures

class  RPMExec
 Execs RPM command and parses its output. More...

Detailed Description

Adapter for the RPM command.

This class provides means to query applications installed via the RPM package manager.


Constructor & Destructor Documentation

hwdet::RPMPackager::RPMPackager ( MessageReporter parent_reporter  ) 

Create new packager.

Parameters:
parent_reporter Message reporter which will receive all messages generated by this class.

hwdet::RPMPackager::~RPMPackager ( void   )  [virtual]

Free used resources.


Member Function Documentation

bool hwdet::RPMPackager::DetectSoftware ( XMLElement products  )  [virtual]

Query data from package manager.

This will exec RPM and parse all data generated by the command.

Parameters:
products XML node which will receive parsed data.
Returns:
true on success, false otherwise.

Implements hwdet::Packager.

bool hwdet::RPMPackager::IsSupported ( void   )  [virtual]

Is packager supported?

Test if RPM is supported. RPM is supported if /bin/rpm file exists and current user has permissions to execute that file.

Returns:
true if RPM is supported, false otherwise.

Implements hwdet::Packager.


Field Documentation

bool hwdet::RPMPackager::is_supported [private]

Is packager supported?


The documentation for this class was generated from the following files:
Generated on Tue Dec 19 17:43:51 2006 for Detector for Linux by  doxygen 1.4.7