Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | Static Private Attributes

ivd_Versions Class Reference
[Common, basic classes, functions and types]

#include <ivd_version.h>

List of all members.

Public Member Functions

 ivd_Versions ()
 ~ivd_Versions ()

Static Public Member Functions

static void AddModuleVersion (const ivd_ModVersion &a_modVersion)
static const string GetProductVersionShort ()
static const string GetProductVersion ()
static const vector< const
ivd_ModVersion * > & 
GetVersions ()
static const string GetVersionString ()
static const string GetVersionStringDetail ()

Private Member Functions

void Add (const ivd_ModVersion &a_modVersion)

Private Attributes

 log_CLASSID_m

Static Private Attributes

static vector< const
ivd_ModVersion * > * 
m_modVersions_p

Detailed Description

Definition at line 108 of file ivd_version.h.


Constructor & Destructor Documentation

ivd_Versions::ivd_Versions (  ) 

Definition at line 157 of file ivd_version.cpp.

                           {
    // Empty
}

ivd_Versions::~ivd_Versions (  ) 

Definition at line 161 of file ivd_version.cpp.

                            {
    // Empty
}


Member Function Documentation

void ivd_Versions::Add ( const ivd_ModVersion a_modVersion  )  [private]

Definition at line 221 of file ivd_version.cpp.

References m_modVersions_p.

Referenced by AddModuleVersion().

                                                         {
    m_modVersions_p->push_back(&a_modVersion);
}

Here is the caller graph for this function:

void ivd_Versions::AddModuleVersion ( const ivd_ModVersion a_modVersion  )  [static]

Definition at line 165 of file ivd_version.cpp.

References Add(), m_modVersions_p, and NULL.

Referenced by ivd_ModVersion::ivd_ModVersion().

                                                                      {
    // Singleton that is instatiated on first use.
    static vector<const ivd_ModVersion*> modVersions;
    static ivd_Versions versions;

    if (g_versionInfo == NULL) {
        modVersions.reserve(10);
        versions.m_modVersions_p = &modVersions;
        g_versionInfo = &versions;
    }
    versions.Add(a_modVersion);
}

Here is the call graph for this function:

Here is the caller graph for this function:

const string ivd_Versions::GetProductVersion (  )  [static]

Definition at line 178 of file ivd_version.cpp.

References m_modVersions_p.

Referenced by log_EventLog::log_EventLog(), and log_EventLog::~log_EventLog().

                                             {

    // last module on the list is binary itself - return it's version
    return (*m_modVersions_p->rbegin())->GetFullVersion();
}

Here is the caller graph for this function:

const string ivd_Versions::GetProductVersionShort (  )  [static]

Definition at line 184 of file ivd_version.cpp.

References m_modVersions_p.

Referenced by bea_Volume::Init().

                                                  {

    // last module on the list is binary itself - return it's version
    return (*m_modVersions_p->rbegin())->GetShortVersion();
}

Here is the caller graph for this function:

const vector< const ivd_ModVersion * > & ivd_Versions::GetVersions (  )  [static]

Definition at line 190 of file ivd_version.cpp.

Referenced by i_Component_i::GetVersion().

Here is the caller graph for this function:

const string ivd_Versions::GetVersionString (  )  [static]

Definition at line 194 of file ivd_version.cpp.

References m_modVersions_p.

Referenced by log_EventLogger::GetHeader(), ut_Group::Header(), ivd_ParseCmnArgs(), and cfg_CliBase::Refresh().

                                            {
    ostringstream sstr;

    for (vector<const ivd_ModVersion *>::reverse_iterator mod = 
         m_modVersions_p->rbegin(); mod != m_modVersions_p->rend(); ++mod) {
        sstr
            << "  " << left << setw(16) << (*mod)->GetModuleName() << " "
            << " " << (*mod)->GetFullVersion() << endl;
    };
    return sstr.str();
}

Here is the caller graph for this function:

const string ivd_Versions::GetVersionStringDetail (  )  [static]

Definition at line 206 of file ivd_version.cpp.

References m_modVersions_p.

Referenced by ivd_ParseCmnArgs(), log_Debugger::On(), and cfg_CliBase::Refresh().

                                                  {
    ostringstream sstr;

    for (vector<const ivd_ModVersion *>::reverse_iterator mod = 
         m_modVersions_p->rbegin(); mod != m_modVersions_p->rend(); ++mod) {
        sstr
            << "  " << left << setw(16) << (*mod)->GetModuleName()
            << " " << (*mod)->GetFullVersion() << endl
            << "\t" << (*mod)->GetBuildTime() << endl
            << "\t" << (*mod)->GetMachineInfo() << endl
            << "\t" << (*mod)->GetCompilerInfo() << endl << endl;
    };
    return sstr.str();
}

Here is the caller graph for this function:


Member Data Documentation

Definition at line 123 of file ivd_version.h.

vector< const ivd_ModVersion * > * ivd_Versions::m_modVersions_p [static, private]

The documentation for this class was generated from the following files: