00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #include <lal/LALStdlib.h>
00021 #include <lal/FrameCache.h>
00022
00023 #include <lal/LALRCSID.h>
00024 NRCSID (FRAMECACHETESTC,"$Id: FrameCacheTest.c,v 1.3 2007/06/08 14:41:46 bema Exp $");
00025
00026 #define TESTSTATUS( pstat ) \
00027 if ( (pstat)->statusCode ) { REPORTSTATUS(pstat); return 1; } else ((void)0)
00028
00029 int lalDebugLevel = 1;
00030
00031 int main( void )
00032 {
00033 static LALStatus status;
00034 static FrCache *input;
00035 static FrCache *cache;
00036 static FrCacheSieve sieve;
00037
00038 LALFrCacheImport( &status, &input, "catalog.test" );
00039 TESTSTATUS( &status );
00040
00041 sieve.srcRegEx = "[F]";
00042 LALFrCacheSieve( &status, &cache, input, &sieve );
00043 TESTSTATUS( &status );
00044
00045 LALFrCacheExport( &status, cache, "catalog.out" );
00046 TESTSTATUS( &status );
00047 LALDestroyFrCache( &status, &cache );
00048 TESTSTATUS( &status );
00049 LALDestroyFrCache( &status, &input );
00050 TESTSTATUS( &status );
00051
00052 LALCheckMemoryLeaks();
00053 return 0;
00054 }