| |
| |
| |
| |
| |
| |
|
|
| |
| |
| |
| |
|
|
| #ifndef LIBSOLV_TRANSACTION_H |
| #define LIBSOLV_TRANSACTION_H |
|
|
| #include "pooltypes.h" |
| #include "queue.h" |
| #include "bitmap.h" |
|
|
| #ifdef __cplusplus |
| extern "C" { |
| #endif |
|
|
| struct s_DUChanges; |
| struct s_TransactionOrderdata; |
|
|
| typedef struct s_Transaction { |
| Pool *pool; |
|
|
| Queue steps; |
|
|
| #ifdef LIBSOLV_INTERNAL |
| Queue transaction_info; |
| Id *transaction_installed; |
| Map transactsmap; |
| Map multiversionmap; |
|
|
| struct s_TransactionOrderdata *orderdata; |
| #endif |
|
|
| } Transaction; |
|
|
|
|
| |
| #define SOLVER_TRANSACTION_IGNORE 0x00 |
|
|
| #define SOLVER_TRANSACTION_ERASE 0x10 |
| #define SOLVER_TRANSACTION_REINSTALLED 0x11 |
| #define SOLVER_TRANSACTION_DOWNGRADED 0x12 |
| #define SOLVER_TRANSACTION_CHANGED 0x13 |
| #define SOLVER_TRANSACTION_UPGRADED 0x14 |
| #define SOLVER_TRANSACTION_OBSOLETED 0x15 |
|
|
| #define SOLVER_TRANSACTION_INSTALL 0x20 |
| #define SOLVER_TRANSACTION_REINSTALL 0x21 |
| #define SOLVER_TRANSACTION_DOWNGRADE 0x22 |
| #define SOLVER_TRANSACTION_CHANGE 0x23 |
| #define SOLVER_TRANSACTION_UPGRADE 0x24 |
| #define SOLVER_TRANSACTION_OBSOLETES 0x25 |
|
|
| #define SOLVER_TRANSACTION_MULTIINSTALL 0x30 |
| #define SOLVER_TRANSACTION_MULTIREINSTALL 0x31 |
|
|
| #define SOLVER_TRANSACTION_MAXTYPE 0x3f |
|
|
| |
| #define SOLVER_TRANSACTION_SHOW_ACTIVE (1 << 0) |
| #define SOLVER_TRANSACTION_SHOW_ALL (1 << 1) |
| #define SOLVER_TRANSACTION_SHOW_OBSOLETES (1 << 2) |
| #define SOLVER_TRANSACTION_SHOW_MULTIINSTALL (1 << 3) |
| #define SOLVER_TRANSACTION_CHANGE_IS_REINSTALL (1 << 4) |
| #define SOLVER_TRANSACTION_MERGE_VENDORCHANGES (1 << 5) |
| #define SOLVER_TRANSACTION_MERGE_ARCHCHANGES (1 << 6) |
|
|
| #define SOLVER_TRANSACTION_RPM_ONLY (1 << 7) |
|
|
| #define SOLVER_TRANSACTION_KEEP_PSEUDO (1 << 8) |
|
|
| #define SOLVER_TRANSACTION_OBSOLETE_IS_UPGRADE (1 << 9) |
|
|
| |
| #define SOLVER_TRANSACTION_ARCHCHANGE 0x100 |
| #define SOLVER_TRANSACTION_VENDORCHANGE 0x101 |
|
|
| |
| #define SOLVER_TRANSACTION_KEEP_ORDERDATA (1 << 0) |
| #define SOLVER_TRANSACTION_KEEP_ORDERCYCLES (1 << 1) |
| #define SOLVER_TRANSACTION_KEEP_ORDEREDGES (1 << 2) |
|
|
| |
| #define SOLVER_ORDERCYCLE_HARMLESS 0 |
| #define SOLVER_ORDERCYCLE_NORMAL 1 |
| #define SOLVER_ORDERCYCLE_CRITICAL 2 |
|
|
| extern Transaction *transaction_create(Pool *pool); |
| extern Transaction *transaction_create_decisionq(Pool *pool, Queue *decisionq, Map *multiversionmap); |
| extern Transaction *transaction_create_clone(Transaction *srctrans); |
| extern void transaction_free(Transaction *trans); |
|
|
| |
| |
| extern Id transaction_obs_pkg(Transaction *trans, Id p); |
| extern void transaction_all_obs_pkgs(Transaction *trans, Id p, Queue *pkgs); |
|
|
| |
| extern Id transaction_type(Transaction *trans, Id p, int mode); |
|
|
| |
| |
| extern void transaction_classify(Transaction *trans, int mode, Queue *classes); |
| extern void transaction_classify_pkgs(Transaction *trans, int mode, Id type, Id from, Id to, Queue *pkgs); |
|
|
| |
| |
| |
| extern int transaction_installedresult(Transaction *trans, Queue *installedq); |
|
|
| long long transaction_calc_installsizechange(Transaction *trans); |
| void transaction_calc_duchanges(Transaction *trans, struct s_DUChanges *mps, int nmps); |
|
|
|
|
|
|
| |
| extern void transaction_order(Transaction *trans, int flags); |
|
|
| |
| |
| |
| |
| extern int transaction_order_add_choices(Transaction *trans, Id chosen, Queue *choices); |
| |
| extern void transaction_add_obsoleted(Transaction *trans); |
|
|
| |
| extern void transaction_check_order(Transaction *trans); |
|
|
| |
| extern void transaction_order_get_cycleids(Transaction *trans, Queue *q, int minseverity); |
| extern int transaction_order_get_cycle(Transaction *trans, Id cid, Queue *q); |
| extern void transaction_order_get_edges(Transaction *trans, Id p, Queue *q, int unbroken); |
|
|
| extern void transaction_free_orderdata(Transaction *trans); |
| extern void transaction_clone_orderdata(Transaction *trans, Transaction *srctrans); |
|
|
| #ifdef __cplusplus |
| } |
| #endif |
|
|
| #endif |
|
|