rpm  4.18.0
rpmfi.h
Go to the documentation of this file.
1 #ifndef H_RPMFI
2 #define H_RPMFI
3 
9 #include <rpm/rpmtypes.h>
10 #include <rpm/rpmfiles.h>
11 #include <rpm/rpmarchive.h>
12 #include <rpm/rpmutil.h>
13 
14 #ifdef __cplusplus
15 extern "C" {
16 #endif
17 
24 
31 
37 int rpmfiFX(rpmfi fi);
38 
45 int rpmfiSetFX(rpmfi fi, int fx);
46 
53 
59 int rpmfiDX(rpmfi fi);
60 
68 int rpmfiSetDX(rpmfi fi, int dx);
69 
75 const char * rpmfiBN(rpmfi fi);
76 
82 const char * rpmfiDN(rpmfi fi);
83 
89 const char * rpmfiFN(rpmfi fi);
90 
99 int rpmfiFindFN(rpmfi fi, const char * fn);
100 
106 const char * rpmfiOBN(rpmfi fi);
107 
113 const char * rpmfiODN(rpmfi fi);
114 
120 const char * rpmfiOFN(rpmfi fi);
121 
130 int rpmfiFindOFN(rpmfi fi, const char * fn);
131 
138 
145 
152 
159 
166 
174 const unsigned char * rpmfiFDigest(rpmfi fi, int *algo, size_t *diglen);
175 
185 char * rpmfiFDigestHex(rpmfi fi, int *algo);
186 
193 const unsigned char * rpmfiFSignature(rpmfi fi, size_t *siglen);
194 
202 const unsigned char * rpmfiVSignature(rpmfi fi, size_t *siglen, uint16_t *algo);
203 
209 const char * rpmfiFLink(rpmfi fi);
210 
217 
224 
231 
238 
245 
251 const char * rpmfiFClass(rpmfi fi);
252 
259 uint32_t rpmfiFDepends(rpmfi fi,
260  const uint32_t ** fddictp);
261 
267 uint32_t rpmfiFNlink(rpmfi fi);
268 
269 
277 uint32_t rpmfiFLinks(rpmfi fi, const int ** files);
278 
285 
291 const char * rpmfiFUser(rpmfi fi);
292 
298 const char * rpmfiFGroup(rpmfi fi);
299 
307 const char * rpmfiFCaps(rpmfi fi);
308 
314 const char * rpmfiFLangs(rpmfi fi);
315 
322 int rpmfiStat(rpmfi fi, int flags, struct stat *sb);
323 
329 int rpmfiNext(rpmfi fi);
330 
337 rpmfi rpmfiInit(rpmfi fi, int fx);
338 
346 
355 rpmfi rpmfiInitD(rpmfi fi, int dx);
356 
363 
373 
382 rpmfi rpmfiNew(const rpmts ts, Header h, rpmTagVal tagN, rpmfiFlags flags);
383 
390 
397 int rpmfiCompare(const rpmfi afi, const rpmfi bfi);
398 
406 
407 #ifdef __cplusplus
408 }
409 #endif
410 
411 #endif /* H_RPMDS */
const char * rpmfiFCaps(rpmfi fi)
Return textual representation of current file capabilities from file info set iterator.
uint32_t rpmfiFNlink(rpmfi fi)
Return (calculated) current file nlink count from file info set iterator.
const char * rpmfiOBN(rpmfi fi)
Return current original base name from file info set iterator.
rpmFileTypes rpmfiWhatis(rpm_mode_t mode)
Return file type from mode_t.
rpm_time_t rpmfiFMtime(rpmfi fi)
Return current file modify time from file info set iterator.
const char * rpmfiDN(rpmfi fi)
Return current directory name from file info set iterator.
int rpmfiFindFN(rpmfi fi, const char *fn)
Return file index of the given file name or -1 if file is not in the rpmfi.
const char * rpmfiFClass(rpmfi fi)
Return current file class from file info set iterator.
rpmfi rpmfiNew(const rpmts ts, Header h, rpmTagVal tagN, rpmfiFlags flags)
Create and load a file info set iterator.
const char * rpmfiODN(rpmfi fi)
Return current original directory name from file info set iterator.
rpmfi rpmfiLink(rpmfi fi)
Reference a file info set iterator instance.
const char * rpmfiFLink(rpmfi fi)
Return current file linkto (i.e.
RPM_GNUC_DEPRECATED int rpmfiNextD(rpmfi fi)
Obsolete, do not use.
const unsigned char * rpmfiFDigest(rpmfi fi, int *algo, size_t *diglen)
Return current file (binary) digest of file info set iterator.
int rpmfiFX(rpmfi fi)
Return current file index from file info set iterator.
rpm_count_t rpmfiDC(rpmfi fi)
Return directory count from file info set iterator.
int rpmfiDX(rpmfi fi)
Return current directory index from file info set iterator.
rpm_mode_t rpmfiFMode(rpmfi fi)
Return current file mode from file info set iterator.
rpmfileState rpmfiFState(rpmfi fi)
Return current file state from file info set iterator.
rpm_count_t rpmfiFC(rpmfi fi)
Return file count from file info set iterator.
rpmfi rpmfiNewPool(rpmstrPool pool, Header h, rpmTagVal tagN, rpmfiFlags flags)
Create and load a file info set iterator.
int rpmfiCompare(const rpmfi afi, const rpmfi bfi)
Return file info comparison.
rpm_color_t rpmfiColor(rpmfi fi)
Return union of all file color bits from file info set iterator.
uint32_t rpmfiFLinks(rpmfi fi, const int **files)
Return (calculated) current file nlink count from file info set iterator.
rpmVerifyAttrs rpmfiVFlags(rpmfi fi)
Return current file verify flags from file info set iterator.
rpm_rdev_t rpmfiFRdev(rpmfi fi)
Return current file rdev from file info set iterator.
const char * rpmfiFGroup(rpmfi fi)
Return current file group from file info set iterator.
int rpmfiFindOFN(rpmfi fi, const char *fn)
Return file index of the given original file name or -1 if file is not in the rpmfi.
int rpmfiSetFX(rpmfi fi, int fx)
Set current file index in file info set iterator.
RPM_GNUC_DEPRECATED int rpmfiSetDX(rpmfi fi, int dx)
Obsolete, do not use.
char * rpmfiFDigestHex(rpmfi fi, int *algo)
Return current file (hex) digest of file info set iterator.
rpm_loff_t rpmfiFSize(rpmfi fi)
Return current file size from file info set iterator.
rpmfi rpmfiFree(rpmfi fi)
Destroy a file info set iterator.
rpmfi rpmfiInit(rpmfi fi, int fx)
Initialize file iterator index.
uint32_t rpmfiFDepends(rpmfi fi, const uint32_t **fddictp)
Return current file depends dictionary from file info set iterator.
const unsigned char * rpmfiFSignature(rpmfi fi, size_t *siglen)
Return current file (binary) signature of file info set iterator.
rpmfileAttrs rpmfiFFlags(rpmfi fi)
Return current file flags from file info set iterator.
rpmVerifyAttrs rpmfiVerify(rpmfi fi, rpmVerifyAttrs omitMask)
Verify file attributes (including digest).
int rpmfiStat(rpmfi fi, int flags, struct stat *sb)
Map file stat(2) info.
const char * rpmfiBN(rpmfi fi)
Return current base name from file info set iterator.
const char * rpmfiFN(rpmfi fi)
Return current file name from file info set iterator.
rpm_ino_t rpmfiFInode(rpmfi fi)
Return current file inode from file info set iterator.
rpm_color_t rpmfiFColor(rpmfi fi)
Return current file color bits from file info set iterator.
const char * rpmfiFUser(rpmfi fi)
Return current file owner from file info set iterator.
int rpmfiNext(rpmfi fi)
Return next file iterator index.
int rpmfiDigestAlgo(rpmfi fi)
Return digest algorithm of a file info set iterator.
const char * rpmfiFLangs(rpmfi fi)
Return current file language(s) from file info set iterator.
const unsigned char * rpmfiVSignature(rpmfi fi, size_t *siglen, uint16_t *algo)
Return current verity (binary) signature of file info set iterator.
RPM_GNUC_DEPRECATED rpmfi rpmfiInitD(rpmfi fi, int dx)
Initialize directory iterator index.
const char * rpmfiOFN(rpmfi fi)
Return current original file name from file info set iterator.
enum rpmFileTypes_e rpmFileTypes
File types.
uint32_t rpm_ino_t
Definition: rpmtypes.h:56
uint32_t rpm_count_t
Definition: rpmtypes.h:29
struct rpmfi_s * rpmfi
Definition: rpmtypes.h:66
struct rpmts_s * rpmts
The main types involved in transaction manipulation.
Definition: rpmtypes.h:63
rpm_tag_t rpmTagVal
Definition: rpmtypes.h:30
uint32_t rpm_color_t
Definition: rpmtypes.h:38
uint16_t rpm_mode_t
Definition: rpmtypes.h:53
uint64_t rpm_loff_t
Definition: rpmtypes.h:51
struct headerToken_s * Header
RPM header and data retrieval types.
Definition: rpmtypes.h:24
uint32_t rpm_time_t
Definition: rpmtypes.h:52
uint16_t rpm_rdev_t
Definition: rpmtypes.h:54
File archive (aka payload) API.
File info set API.
enum rpmfileState_e rpmfileState
File States (when installed).
rpmFlags rpmfileAttrs
Definition: rpmfiles.h:64
rpmFlags rpmVerifyAttrs
Definition: rpmfiles.h:94
rpmFlags rpmfiFlags
Definition: rpmfiles.h:158
Typedefs for RPM abstract data types.
struct rpmstrPool_s * rpmstrPool
Definition: rpmtypes.h:84
Miscellaneous utility macros:
#define RPM_GNUC_DEPRECATED
Definition: rpmutil.h:81