fwInstallation  8.4.1
Functions | Variables
fwInstallationDBCache.ctl File Reference

Functions

string _fwInstallationDbCache_getCacheKey (string functionKey, dyn_mixed parameters, string index="")
 
int fwInstallationDBCache_setCaches (string functionKey, dyn_mixed parameters, dyn_anytype values, dyn_string valuesIndexes)
 
int fwInstallationDBCache_setCache (string functionKey, dyn_mixed parameters, anytype value, string index="")
 
int fwInstallationDBCache_getCache (string functionKey, dyn_mixed parameters, anytype &returnValue, string index="")
 

Variables

const string csFwInstallationDBCacheLibVersion = "8.4.1"
 

Detailed Description

This library contains the implementation of cache functions to the fwInstallationDB interface.

Author
Daniel Rodrigues (EN-ICE/SIC)
Version
0.6 corrected error on _fwInstallationDbCache_getCacheKey
Date
August 2011

version 0.6 adding an useCache flag, normally set to false, only true if initialized. eliminating the uptodate mechanism (clearing the db not so elegant but working) version 0.5 changing a mapping based cache, depending on function names and parameters version 0.3 Testing version version 0.2 modifying architecture: new "setCache" parameter, cache controlled from fwInstallationDB to avoid infinite loop cache set from outside. version 0.1 Initial porting of all functions with SELECT import

TODO: think about having a get/set tuple for each function instead of "loadCache"

Function Documentation

string _fwInstallationDbCache_getCacheKey ( string  functionKey,
dyn_mixed  parameters,
string  index = "" 
)

gets cache key based on function name, parameterValues, value, etc.

int fwInstallationDBCache_setCaches ( string  functionKey,
dyn_mixed  parameters,
dyn_anytype  values,
dyn_string  valuesIndexes 
)

Set a number of cache values.

alternative

int fwInstallationDBCache_setCache ( string  functionKey,
dyn_mixed  parameters,
anytype  value,
string  index = "" 
)

Set value in Cache for a given function, parameters, and index

Returns
0 of successful TODO : evaluate possibility of non forcable flag (return -1 if value already in cache)
int fwInstallationDBCache_getCache ( string  functionKey,
dyn_mixed  parameters,
anytype &  returnValue,
string  index = "" 
)

Get cached value for function, parameters, index to &value

Returns
0 if successful
-1 if value is not cached.
-2 if cache is not to be used.

Variable Documentation

const string csFwInstallationDBCacheLibVersion = "8.4.1"

This script implements an interface to the gDbCache object for the installation tool

  1. All functions that select information from the database in fwInstallationDB are replicated in gDbCache a. Stored as a compound string of functionname::(parameters:);
  2. Returns the necessary variable if: a. gDbCache is uptodate (gDbCache["isUptodate"] == true ) and b. mapping exists for the compound string exists and c. loadCache = false.
  3. if loadCache is true, a. Sets the mapping compoundstring, value(s) Version of this library. Used to determine the coherency of all libraries of the installation tool Please do not edit it manually