24 #include <lal/LALDatatypes.h>
25 #include <lal/FileIO.h>
50 struct tagLALCacheEntry;
54 typedef struct tagLALCacheEntry {
63 typedef struct tagLALCache {
121 const char *srcregex,
const char *dscregex,
122 const char *urlregex);
140 #if defined(__cplusplus)
LALCache * XLALCreateCache(UINT4 length)
Creates a LALCache structure.
LALFILE * XLALCacheEntryOpen(const LALCacheEntry *entry)
Open a file identified by an entry in a LALCache structure.
LALCache * XLALCacheImport(const char *fname)
Reads a LAL cache file and produces a LALCache structure.
LALCache * XLALCacheMerge(const LALCache *cache1, const LALCache *cache2)
Returns a new LALCache structure that is the merge of two.
void XLALDestroyCache(LALCache *cache)
Destroys a LALCache structure.
LALCache * XLALCacheGlob(const char *dirstr, const char *fnptrn)
Globs a directory and construct LALCache from matching entries.
LALCacheEntry * XLALCacheEntrySeek(const LALCache *cache, double t)
Finds the first entry that contains the requested time, or the first entry after the time if the time...
int XLALCacheFileWrite(LALFILE *fp, const LALCache *cache)
Writes a LALCache structure to output LALFILE.
LALCache * XLALCacheFileRead(LALFILE *fp)
Reads a LAL cache file and produces a LALCache structure.
int XLALCacheUniq(LALCache *cache)
Prunes duplicate entries keeping the second one; cache is reduced in length if there are.
int XLALCacheExport(const LALCache *cache, const char *filename)
Exports a LALCache structure to an output LAL cache file.
int XLALCacheSort(LALCache *cache)
Sorts entries in a LALCache structure.
int XLALCacheSieve(LALCache *cache, INT4 t0, INT4 t1, const char *srcregex, const char *dscregex, const char *urlregex)
Selects only matching entries in a LALCache structure – other entries are deleted from the LALCache s...
LALCache * XLALCacheDuplicate(const LALCache *cache)
Duplicates a LALCache structure.
char CHAR
One-byte signed integer, see Headers LAL(Atomic)Datatypes.h for more details.
uint32_t UINT4
Four-byte unsigned integer.
int32_t INT4
Four-byte signed integer.
CHAR * src
File source field.
CHAR * dsc
File description field.
INT4 t0
GPS time (seconds) of beginning of data in file.
INT4 dt
Duration (seconds) of data in file.
The LALCache structure is an array of entries.