Go to the documentation of this file.
9 #include <rpm/rpmtypes.h>
10 #include <rpm/rpmsw.h>
91 const unsigned int * hdrNums,
unsigned int nHdrNums);
129 rpmRC (*hdrchk) (
rpmts ts,
const void * uh,
size_t uc,
char ** msg));
140 const void * keyp,
size_t keylen);
244 int rpmdbStat(
const char *prefix,
struct stat *statbuf);
enum rpmMireMode_e rpmMireMode
Tag value pattern match mode.
int rpmdbSetIteratorRewrite(rpmdbMatchIterator mi, int rewrite)
Prepare iterator for lazy writes.
enum rpmDbiTag_e rpmDbiTag
Rpm database index tags.
struct rpmts_s * rpmts
The main types involved in transaction manipulation.
int rpmdbOpenAll(rpmdb db)
Open all database indices.
rpmdbMatchIterator rpmdbInitIterator(rpmdb db, rpmDbiTagVal rpmtag, const void *keyp, size_t keylen)
Return database iterator.
unsigned int rpmdbGetIteratorFileNum(rpmdbMatchIterator mi)
unsigned int rpmdbIndexIteratorTagNum(rpmdbIndexIterator ii, unsigned int nr)
Get tag number of entry.
int rpmdbFStat(rpmdb db, struct stat *statbuf)
Perform stat() on an open rpm database.
int rpmdbGetIteratorCount(rpmdbMatchIterator mi)
Return number of elements in rpm database iterator.
rpmdbIndexIterator rpmdbIndexIteratorInit(rpmdb db, rpmDbiTag rpmtag)
Get an iterator for an index.
enum rpmRC_e rpmRC
Package read return codes.
rpmop rpmdbOp(rpmdb db, rpmdbOpX opx)
Retrieve operation timestamp from rpm database.
char * rpmdbCookie(rpmdb db)
Retrieve rpm database changed-cookie.
int rpmdbStat(const char *prefix, struct stat *statbuf)
Perform stat() on rpm database.
int rpmdbSetHdrChk(rpmdbMatchIterator mi, rpmts ts, rpmRC(*hdrchk)(rpmts ts, const void *uh, size_t uc, char **msg))
Modify iterator to verify retrieved header blobs.
unsigned int rpmdbGetIteratorOffset(rpmdbMatchIterator mi)
Return header join key for current position of rpm database iterator.
struct rpmdbIndexIterator_s * rpmdbIndexIterator
struct rpmdbMatchIterator_s * rpmdbMatchIterator
int rpmdbIndexIteratorNext(rpmdbIndexIterator ii, const void **key, size_t *keylen)
Get the next key - Warning! Keys are not zero terminated! Binary tags may even contain zero bytes.
rpmdbIndexIterator rpmdbIndexKeyIteratorInit(rpmdb db, rpmDbiTag rpmtag)
Get an iterator for index keys.
rpmdbMatchIterator rpmdbFreeIterator(rpmdbMatchIterator mi)
Destroy rpm database iterator.
int rpmdbSetIteratorModified(rpmdbMatchIterator mi, int modified)
Modify iterator to mark header for lazy write on release.
int rpmdbCtrl(rpmdb db, rpmdbCtrlOp ctrl)
manipulate the rpm database
int rpmdbSetIteratorRE(rpmdbMatchIterator mi, rpmTagVal tag, rpmMireMode mode, const char *pattern)
Add pattern to iterator selector.
Container for rpm tag data (from headers or extensions).
unsigned int rpmdbIndexIteratorPkgOffset(rpmdbIndexIterator ii, unsigned int nr)
Get package offset of entry.
unsigned int rpmdbIndexIteratorNumPkgs(rpmdbIndexIterator ii)
Get number of entries for current key.
int rpmdbAppendIterator(rpmdbMatchIterator mi, const unsigned int *hdrNums, unsigned int nHdrNums)
Append items to set of package instances to iterate.
int rpmdbIndexIteratorNextTd(rpmdbIndexIterator ii, rpmtd keytd)
Get the next key into a tag data container.
Cumulative statistics for an operation.
struct headerToken_s * Header
RPM header and data retrieval types.
enum rpmdbCtrlOp_e rpmdbCtrlOp
rpmMireMode_e
Tag value pattern match mode.
Header rpmdbNextIterator(rpmdbMatchIterator mi)
Return next package header from iteration.
rpmdbIndexIterator rpmdbIndexIteratorFree(rpmdbIndexIterator ii)
Free index iterator.
int rpmdbCountPackages(rpmdb db, const char *name)
Return number of instances of package in rpm database.