Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   Related Pages  

libsvx::Product Class Reference

The class containing Product informations <product></product>. More...

#include <product.h>

Inheritance diagram for libsvx::Product:

libsvx::ElementName libsvx::ElementUid libsvx::ElementLicense libsvx::ElementGeneric libsvx::ElementGeneric libsvx::ElementGeneric libsvx::Element libsvx::Element libsvx::Element List of all members.

Public Methods

 Product (TiXmlElement &Element)
 Create an SVX Product Element based on an XML element. More...

 ~Product ()
 destructor, free all the sub-informations.

bool IsValid () const
 Valid ??? More...

TiXmlElement & XmlElement ()
 a method to get the informations of the element into an XML element.

const AttributeHREF () const
 The URL to get updated info of the element (href="xxx").

Product & operator+= (const Product &the_object_to_add)
 Add the content of the new product to this object. More...

bool operator!= (const Product &the_object_to_compare) const
bool IsOldVersion (const std::string &the_version_to_check) const
const VersionGetLatestVersion ()
 Retrieve the newest version of the product. More...

VersionFindVersion (const std::string &the_version_name)
 Find the specified Version in the Product data.

void Iterate_Version_Begin ()
 Find the specified Version in the Product data / Version * Product::FindVersion(const Version & the_version) const { std::list<Version *>const_iterator current_version = m_List_Version.begin(); Put the Product internal iterator on the first document.

bool Iterate_Version_IsBegin ()
 Specify wether there is still a Version available before in the list.

bool Iterate_Version_IsEnd ()
 Specify wether there is still a Version available next in the list.

const std::string & Iterate_Version_Next ()
 Return the name of the next Version in line.

const std::string & Iterate_Version_Prev ()
 Return the name of the next Version in line.


Protected Attributes

Attributem_A_href
 The URL to get updated versions of this SVX section.

Attributem_A_ihref
 The URL to get updated informations on the package.

Vendorm_Vendor
 The vendor informations.

Descriptionm_Description
 A list of description texts to describe the product in details.

Mvector< Versionm_List_Version
 The list of versions of the "product".

size_t m_Iterator_Version
 The current Product iterator.


Detailed Description

The class containing Product informations <product></product>.

Definition at line 67 of file product.h.


Constructor & Destructor Documentation

Product::Product TiXmlElement &    a_Element
 

Create an SVX Product Element based on an XML element.

Todo:
sort the version list (by date) after the addition

Definition at line 61 of file product.cxx.

References m_A_href, m_A_ihref, m_Description, m_Iterator_Version, m_List_Version, and m_Vendor.


Member Function Documentation

const Version * Product::GetLatestVersion  
 

Retrieve the newest version of the product.

Todo:
finish sorting
Returns:
false if no version exists

Definition at line 188 of file product.cxx.

References m_List_Version, and libsvx::Mvector< Version >::sort().

Referenced by libsvx::Document::GetLatestProductVersion().

bool Product::IsValid   const [virtual]
 

Valid ???

Todo:
verify the HREFs validity

Reimplemented from libsvx::ElementLicense.

Definition at line 135 of file product.cxx.

References libsvx::ElementName::m_A_name, libsvx::ElementUid::m_A_uid, and m_List_Version.

Referenced by operator+=().

Product & Product::operator+= const Product &    the_object_to_add
 

Add the content of the new product to this object.

Todo:
treat m_List_Version

updating the name and license should be configurable

Definition at line 220 of file product.cxx.

References FindVersion(), IsValid(), m_A_href, m_A_ihref, libsvx::ElementUid::m_A_uid, m_Description, m_List_Version, m_Vendor, libsvx::Attribute::String(), and libsvx::ElementUid::UID().


The documentation for this class was generated from the following files:
Generated on Sat Apr 13 15:45:49 2002 for libsvx by doxygen1.2.15