GLAST / LAT > DAQ and FSW > FSW > Doxygen Index> QSP / V0-2-1 > qsp / linux-gcc
#include "QSP/QFCH_cache.h"
#include "QSP/QSP_templates.h"
#include "QSD/QFC_cache.h"
#include "QSD/QFC_member.h"
Classes | |
struct | _QFCH_cache |
The cache of master file keys and their configurations. More... | |
Defines | |
#define | NMASTERS 32 |
#define | NCFGS 32 |
#define | NULL ((void *)0) |
Typedefs | |
typedef struct _QFCH_cache | QFCH_cache |
Functions | |
int | QFCH_sizeof (int depth) |
Returns the size, in bytes, of a handler file cache. | |
void * | QFCH_construct (QFCH_cache *cache, int depth) |
Constructs a handler cache of the requested depth. | |
void | QFCH_destruct (QFCH_cache *cache) |
Destroys the cache. | |
QFC_cache * | QFCH_masterLocate (QFCH_cache *cache, unsigned int hid) |
Returns a pointer to the requested handler's master cache. | |
QFC_cache * | QFCH_cfgLocate (QFCH_cache *cache, unsigned int hid, unsigned int cid) |
Returns a pointer to the requested handler's configuration cache. | |
int | QFCH_masterResolve (QFCH_cache *cache, QFR_fileCtx *qfr, QFC_file *file, unsigned int key, const QSP_templates *templates, unsigned int hid) |
Resolves the reference for the requested handler's master file. | |
int | QFCH_cfgResolve (QFCH_cache *cache, QFR_fileCtx *qfr, QFC_file *file, unsigned int key, const QSP_templates *templates, unsigned int hid, unsigned int cid) |
Resolves the reference for the requested handler's configuration file. |
CVS $Id: QFCH_cache.c,v 1.2 2008/06/09 19:59:57 russell Exp $
QFC_cache* QFCH_cfgLocate | ( | QFCH_cache * | cache, | |
unsigned int | hid, | |||
unsigned int | cid | |||
) |
Returns a pointer to the requested handler's configuration cache.
cache | The handler's file cache | |
hid | The handler identifier | |
cid | The configuration identifier |
int QFCH_cfgResolve | ( | QFCH_cache * | cache, | |
QFR_fileCtx * | qfr, | |||
QFC_file * | file, | |||
unsigned int | key, | |||
const QSP_templates * | templates, | |||
unsigned int | hid, | |||
unsigned int | cid | |||
) |
Resolves the reference for the requested handler's configuration file.
== | 0, if successful | |
== | -1, if reference could not be resolved |
cache | The handler's file cache | |
qfr | File resolution context (usually holds the FMX handle) | |
file | The file structure to receive the resolved file | |
key | The file key | |
templates | The templates to build a file name from. This is only used when the key is a CMX style key | |
hid | The handler identifier | |
cid | The configuration identifier |
void* QFCH_construct | ( | QFCH_cache * | cache, | |
int | depth | |||
) |
Constructs a handler cache of the requested depth.
cache | The memory in which the cache will be constructed. It is assumed that this memory has been properly sized using QFCH_sizeof. | |
depth | The depth of the cache |
void QFCH_destruct | ( | QFCH_cache * | cache | ) |
Destroys the cache.
cache | The cache to destroy |
QFC_cache* QFCH_masterLocate | ( | QFCH_cache * | cache, | |
unsigned int | hid | |||
) |
Returns a pointer to the requested handler's master cache.
cache | The handler's file cache | |
hid | The handler identifier |
int QFCH_masterResolve | ( | QFCH_cache * | cache, | |
QFR_fileCtx * | qfr, | |||
QFC_file * | file, | |||
unsigned int | key, | |||
const QSP_templates * | templates, | |||
unsigned int | hid | |||
) |
Resolves the reference for the requested handler's master file.
== | 0, if successful | |
== | -1, if reference could not be resolved |
cache | The handler's file cache | |
qfr | File resolution context (usually holds the FMX handle) | |
file | The file structure to receive the resolved file | |
key | The file key | |
templates | The names to build a file name from. This is only used when the key is a CMX style key | |
hid | The handler identifier |
int QFCH_sizeof | ( | int | depth | ) |
Returns the size, in bytes, of a handler file cache.
depth | The depth of the cache. This determines how many versions of each file may be cached at any given time. |