rpmdb.h
Go to the documentation of this file.
#ifndef H_RPMDB
#define H_RPMDB
#include <rpm/rpmtypes.h>
#include <rpm/rpmsw.h>
#ifdef __cplusplus
extern "C" {
#endif
typedef enum rpmMireMode_e {
RPMMIRE_DEFAULT = 0,
RPMMIRE_STRCMP = 1,
RPMMIRE_REGEX = 2,
RPMMIRE_GLOB = 3
} rpmMireMode;
typedef enum rpmdbOpX_e {
RPMDB_OP_DBGET = 1,
RPMDB_OP_DBPUT = 2,
RPMDB_OP_DBDEL = 3,
RPMDB_OP_MAX = 4
} rpmdbOpX;
rpmop rpmdbOp(rpmdb db, rpmdbOpX opx);
int rpmdbOpenAll (rpmdb db);
int rpmdbCountPackages(rpmdb db, const char * name);
unsigned int rpmdbGetIteratorOffset(rpmdbMatchIterator mi);
int rpmdbGetIteratorCount(rpmdbMatchIterator mi);
unsigned int rpmdbGetIteratorFileNum(rpmdbMatchIterator mi);
int rpmdbAppendIterator(rpmdbMatchIterator mi,
const int * hdrNums, int nHdrNums);
int rpmdbSetIteratorRE(rpmdbMatchIterator mi, rpmTagVal tag,
rpmMireMode mode, const char * pattern);
int rpmdbSetIteratorRewrite(rpmdbMatchIterator mi, int rewrite);
int rpmdbSetIteratorModified(rpmdbMatchIterator mi, int modified);
int rpmdbSetHdrChk(rpmdbMatchIterator mi, rpmts ts,
rpmRC (*hdrchk) (rpmts ts, const void * uh, size_t uc, char ** msg));
rpmdbMatchIterator rpmdbInitIterator(rpmdb db, rpmDbiTagVal rpmtag,
const void * keyp, size_t keylen);
Header rpmdbNextIterator(rpmdbMatchIterator mi);
int rpmdbCheckSignals(void);
int rpmdbCheckTerminate(int terminate);
rpmdbMatchIterator rpmdbFreeIterator(rpmdbMatchIterator mi);
rpmdbIndexIterator rpmdbIndexIteratorInit(rpmdb db, rpmDbiTag rpmtag);
int rpmdbIndexIteratorNext(rpmdbIndexIterator ii, const void ** key, size_t * keylen);
unsigned int rpmdbIndexIteratorNumPkgs(rpmdbIndexIterator ii);
unsigned int rpmdbIndexIteratorPkgOffset(rpmdbIndexIterator ii, unsigned int nr);
unsigned int rpmdbIndexIteratorTagNum(rpmdbIndexIterator ii, unsigned int nr);
rpmdbIndexIterator rpmdbIndexIteratorFree(rpmdbIndexIterator ii);
#ifdef __cplusplus
}
#endif
#endif /* H_RPMDB */