comparison audioDB.h @ 393:fd9b65e5ca95 api-inversion

There can be only one (again). I think I see how it arose, but there's in fact no need to have two separate status structures ("struct adbstatus" and "struct cppstatus"). Delete "struct cppstatus" and simplify audioDB::status accordingly.
author mas01cr
date Tue, 25 Nov 2008 16:40:59 +0000
parents 78fed0d4c108
children bc7a821004bb
comparison
equal deleted inserted replaced
392:78fed0d4c108 393:fd9b65e5ca95
201 off_t l2normTableOffset; 201 off_t l2normTableOffset;
202 off_t timesTableOffset; 202 off_t timesTableOffset;
203 off_t powerTableOffset; 203 off_t powerTableOffset;
204 off_t dbSize; 204 off_t dbSize;
205 } dbTableHeaderT, *dbTableHeaderPtr; 205 } dbTableHeaderT, *dbTableHeaderPtr;
206
207 typedef struct {
208
209 unsigned numFiles;
210 unsigned dim;
211 unsigned length;
212 unsigned dudCount;
213 unsigned nullCount;
214 unsigned flags;
215
216
217 } cppstatus, *cppstatusptr;
218 206
219 class PointPair{ 207 class PointPair{
220 public: 208 public:
221 Uns32T trackID; 209 Uns32T trackID;
222 Uns32T qpos; 210 Uns32T qpos;
358 audioDB(const unsigned argc, const char *argv[]); 346 audioDB(const unsigned argc, const char *argv[]);
359 audioDB(const unsigned argc, const char *argv[], adb__queryResponse *adbQueryResponse); 347 audioDB(const unsigned argc, const char *argv[], adb__queryResponse *adbQueryResponse);
360 audioDB(const unsigned argc, const char *argv[], adb__statusResponse *adbStatusResponse); 348 audioDB(const unsigned argc, const char *argv[], adb__statusResponse *adbStatusResponse);
361 audioDB(const unsigned argc, const char *argv[], adb__lisztResponse *adbLisztResponse); 349 audioDB(const unsigned argc, const char *argv[], adb__lisztResponse *adbLisztResponse);
362 audioDB(const unsigned argc, const char *argv[], int * apierror); 350 audioDB(const unsigned argc, const char *argv[], int * apierror);
363 audioDB(const unsigned argc, const char *argv[], cppstatusptr stat, int * apierror); 351 audioDB(const unsigned argc, const char *argv[], struct adbstatus *status, int * apierror);
364 audioDB(const unsigned argc, const char *argv[],adb__queryResponse *adbQueryResponse, int * apierror); 352 audioDB(const unsigned argc, const char *argv[],adb__queryResponse *adbQueryResponse, int * apierror);
365 353
366 354
367 void cleanup(); 355 void cleanup();
368 ~audioDB(); 356 ~audioDB();
376 void insert(const char* dbName, const char* inFile); 364 void insert(const char* dbName, const char* inFile);
377 void batchinsert(const char* dbName, const char* inFile); 365 void batchinsert(const char* dbName, const char* inFile);
378 void batchinsert_large_adb(const char* dbName, const char* inFile); 366 void batchinsert_large_adb(const char* dbName, const char* inFile);
379 void query(const char* dbName, const char* inFile, adb__queryResponse *adbQueryResponse=0); 367 void query(const char* dbName, const char* inFile, adb__queryResponse *adbQueryResponse=0);
380 void status(const char* dbName, adb__statusResponse *adbStatusResponse=0); 368 void status(const char* dbName, adb__statusResponse *adbStatusResponse=0);
381 void status(const char* dbName, cppstatusptr status); 369 void status(const char* dbName, struct adbstatus *status);
382 370
383 unsigned random_track(unsigned *propTable, unsigned total); 371 unsigned random_track(unsigned *propTable, unsigned total);
384 void sample(const char *dbName); 372 void sample(const char *dbName);
385 void l2norm(const char* dbName); 373 void l2norm(const char* dbName);
386 void power_flag(const char *dbName); 374 void power_flag(const char *dbName);