rpm 4.10.0

- Main Page
- Related Pages
- Modules
- Data Structures
- Files

Files | Typedefs | Enumerations | Functions
Transaction Element API.
Collaboration diagram for Transaction Element API.:

## Files
file | rpmte.h
| Structures used for an "rpmte" transaction element.
## Typedefs
typedef enum rpmElementType_e | rpmElementType
| Transaction element type.
## Enumerations
enum | rpmElementType_e { TR_ADDED = (1 << 0), TR_REMOVED = (1 << 1) }
| Transaction element type. More...
## Functions
Header | rpmteHeader (rpmte te)
| Retrieve header from transaction element.
Header | rpmteSetHeader (rpmte te, Header h)
| Save header into transaction element.
rpmElementType | rpmteType (rpmte te)
| Retrieve type of transaction element.
const char * | rpmteN (rpmte te)
| Retrieve name string of transaction element.
const char * | rpmteE (rpmte te)
| Retrieve epoch string of transaction element.
const char * | rpmteV (rpmte te)
| Retrieve version string of transaction element.
const char * | rpmteR (rpmte te)
| Retrieve release string of transaction element.
const char * | rpmteA (rpmte te)
| Retrieve arch string of transaction element.
const char * | rpmteO (rpmte te)
| Retrieve os string of transaction element.
int | rpmteIsSource (rpmte te)
| Retrieve isSource attribute of transaction element.
rpm_color_t | rpmteColor (rpmte te)
| Retrieve color bits of transaction element.
rpm_color_t | rpmteSetColor (rpmte te, rpm_color_t color)
| Set color bits of transaction element.
unsigned int | rpmteDBInstance (rpmte te)
| Retrieve last instance installed to the database.
void | rpmteSetDBInstance (rpmte te, unsigned int instance)
| Set last instance installed to the database.
rpm_loff_t | rpmtePkgFileSize (rpmte te)
| Retrieve size in bytes of package file.
rpmte | rpmteParent (rpmte te)
| Retrieve parent transaction element.
rpmte | rpmteSetParent (rpmte te, rpmte pte)
| Set parent transaction element.
rpmps | rpmteProblems (rpmte te)
| Return problem set info of transaction element.
void | rpmteCleanProblems (rpmte te)
| Destroy problem set info of transaction element.
void | rpmteCleanDS (rpmte te)
| Destroy dependency set info of transaction element.
void | rpmteSetDependsOn (rpmte te, rpmte depends)
| Set dependent element of TR_REMOVED transaction element.
rpmte | rpmteDependsOn (rpmte te)
| Retrieve dependent element of TR_REMOVED transaction element.
int | rpmteDBOffset (rpmte te)
| Retrieve rpmdb instance of TR_REMOVED transaction element.
const char * | rpmteEVR (rpmte te)
| Retrieve [epoch:]version-release string from transaction element.
const char * | rpmteNEVR (rpmte te)
| Retrieve name-[epoch:]version-release string from transaction element.
const char * | rpmteNEVRA (rpmte te)
| Retrieve name-[epoch:]version-release.arch string from transaction element.
fnpyKey | rpmteKey (rpmte te)
| Retrieve key from transaction element.
int | rpmteFailed (rpmte te)
| Return failure status of transaction element.
rpmds | rpmteDS (rpmte te, rpmTagVal tag)
| Retrieve dependency tag set from transaction element.
rpmfi | rpmteFI (rpmte te)
| Retrieve file info tag set from transaction element.
ARGV_const_t | rpmteCollections (rpmte te)
| Retrieve list of collections.
int | rpmteHasCollection (rpmte te, const char *collname)
| Determine a transaction element is part of a collection.
rpmtsi | rpmtsiFree (rpmtsi tsi)
| Destroy transaction element iterator.
rpmtsi | rpmtsiInit (rpmts ts)
| Create transaction element iterator.
rpmte | rpmtsiNext (rpmtsi tsi, rpmElementTypes types)
| Return next transaction element of type.

## Typedef Documentation

typedef enum rpmElementType_e rpmElementType

Transaction element type.

## Enumeration Type Documentation

enum rpmElementType_e

Transaction element type.

Enumerator:

  TR_ADDED | Package will be installed.
  TR_REMOVED | Package will be removed.

Definition at line 19 of file rpmte.h.

## Function Documentation

const char* rpmteA | ( | rpmte | te | ) |

Retrieve arch string of transaction element.

Parameters:

  te | transaction element

Returns:
  arch string

void rpmteCleanDS | ( | rpmte | te | ) |

Destroy dependency set info of transaction element.

Parameters:

  te | transaction element

void rpmteCleanProblems | ( | rpmte | te | ) |

Destroy problem set info of transaction element.

Parameters:

  te | transaction element

ARGV_const_t rpmteCollections | ( | rpmte | te | ) |

Retrieve list of collections.

Parameters:

  te | transaction element

Returns:
  list of collections

rpm_color_t rpmteColor | ( | rpmte | te | ) |

Retrieve color bits of transaction element.

Parameters:

  te | transaction element

Returns:
  color bits

unsigned int rpmteDBInstance | ( | rpmte | te | ) |

Retrieve last instance installed to the database.

Parameters:

  te | transaction element

Returns:
  last install instance.

int rpmteDBOffset | ( | rpmte | te | ) |

Retrieve rpmdb instance of TR_REMOVED transaction element.

Parameters:

  te | transaction element

Returns:
  rpmdb instance

rpmte rpmteDependsOn | ( | rpmte | te | ) |

Retrieve dependent element of TR_REMOVED transaction element.

Parameters:

  te | transaction element

Returns:
  dependent transaction element

rpmds rpmteDS | ( | rpmte | te,
|  | rpmTagVal | tag
| ) |  |

Retrieve dependency tag set from transaction element.

Parameters:

  te | transaction element
  tag | dependency tag

Returns:
  dependency tag set

const char* rpmteE | ( | rpmte | te | ) |

Retrieve epoch string of transaction element.

Parameters:

  te | transaction element

Returns:
  epoch string

const char* rpmteEVR | ( | rpmte | te | ) |

Retrieve [epoch:]version-release string from transaction element.

Parameters:

  te | transaction element

Returns:
  [epoch:]version-release string

int rpmteFailed | ( | rpmte | te | ) |

Return failure status of transaction element.

If the element itself failed, this is 1, larger count means one of it's parents failed.

Parameters:

  te | transaction element

Returns:
  number of failures for this transaction element

rpmfi rpmteFI | ( | rpmte | te | ) |

Retrieve file info tag set from transaction element.

Parameters:

  te | transaction element

Returns:
  file info tag set

int rpmteHasCollection | ( | rpmte | te,
|  | const char * | collname
| ) |  |

Determine a transaction element is part of a collection.

Parameters:

  te | transaction element
  collname | collection name

Returns:
  1 if collname is part of a collection, 0 if not

Header rpmteHeader | ( | rpmte | te | ) |

Retrieve header from transaction element.

Parameters:

  te | transaction element

Returns:
  header (new reference)

int rpmteIsSource | ( | rpmte | te | ) |

Retrieve isSource attribute of transaction element.

Parameters:

  te | transaction element

Returns:
  isSource attribute

fnpyKey rpmteKey | ( | rpmte | te | ) |

Retrieve key from transaction element.

Parameters:

  te | transaction element

Returns:
  key

const char* rpmteN | ( | rpmte | te | ) |

Retrieve name string of transaction element.

Parameters:

  te | transaction element

Returns:
  name string

const char* rpmteNEVR | ( | rpmte | te | ) |

Retrieve name-[epoch:]version-release string from transaction element.

Parameters:

  te | transaction element

Returns:
  name-[epoch:]version-release string

const char* rpmteNEVRA | ( | rpmte | te | ) |

Retrieve name-[epoch:]version-release.arch string from transaction element.

Parameters:

  te | transaction element

Returns:
  name-[epoch:]version-release.arch string

const char* rpmteO | ( | rpmte | te | ) |

Retrieve os string of transaction element.

Parameters:

  te | transaction element

Returns:
  os string

rpmte rpmteParent | ( | rpmte | te | ) |

Retrieve parent transaction element.

Parameters:

  te | transaction element

Returns:
  parent transaction element

rpm_loff_t rpmtePkgFileSize | ( | rpmte | te | ) |

Retrieve size in bytes of package file.

Todo:
  Signature header is estimated at 256b.

Parameters:

  te | transaction element

Returns:
  size in bytes of package file.

rpmps rpmteProblems | ( | rpmte | te | ) |

Return problem set info of transaction element.

Parameters:

  te | transaction element

Returns:
  problem set (or NULL if none)

const char* rpmteR | ( | rpmte | te | ) |

Retrieve release string of transaction element.

Parameters:

  te | transaction element

Returns:
  release string

rpm_color_t rpmteSetColor | ( | rpmte | te,
|  | rpm_color_t | color
| ) |  |

Set color bits of transaction element.

Parameters:

  te | transaction element
  color | new color bits

Returns:
  previous color bits

void rpmteSetDBInstance | ( | rpmte | te,
|  | unsigned int | instance
| ) |  |

Set last instance installed to the database.

Parameters:

  te | transaction element
  instance | Database instance of last install element.

Returns:
  last install instance.

void rpmteSetDependsOn | ( | rpmte | te,
|  | rpmte | depends
| ) |  |

Set dependent element of TR_REMOVED transaction element.

Parameters:

  te | transaction element
  depends | dependent transaction element

Header rpmteSetHeader | ( | rpmte | te,
|  | Header | h
| ) |  |

Save header into transaction element.

Parameters:

  te | transaction element
  h | header

Returns:
  NULL always

rpmte rpmteSetParent | ( | rpmte | te,
|  | rpmte | pte
| ) |  |

Set parent transaction element.

Parameters:

  te | transaction element
  pte | new parent transaction element

Returns:
  previous parent transaction element

rpmElementType rpmteType | ( | rpmte | te | ) |

Retrieve type of transaction element.

Parameters:

  te | transaction element

Returns:
  type

const char* rpmteV | ( | rpmte | te | ) |

Retrieve version string of transaction element.

Parameters:

  te | transaction element

Returns:
  version string

rpmtsi rpmtsiFree | ( | rpmtsi | tsi | ) |

Destroy transaction element iterator.

Parameters:

  tsi | transaction element iterator

Returns:
  NULL always

rpmtsi rpmtsiInit | ( | rpmts | ts | ) |

Create transaction element iterator.

Parameters:

  ts | transaction set

Returns:
  transaction element iterator

rpmte rpmtsiNext | ( | rpmtsi | tsi,
|  | rpmElementTypes | types
| ) |  |

Return next transaction element of type.

Parameters:

  tsi | transaction element iterator
  types | transaction element type selector (0 for any)

Returns:
  next transaction element of type, NULL on termination