blob: 84556a09fc958d2fd83a07e81221714ade49a77f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
|
#ifndef APT_PRIVATE_HISTORY_H
#define APT_PRIVATE_HISTORY_H
#include <apt-pkg/cmndline.h>
#include <apt-pkg/history.h>
#include <apt-pkg/macros.h>
#include <apt-pkg/tagfile.h>
APT_PUBLIC bool DoHistoryInfo(CommandLine &Cmd);
APT_PUBLIC bool DoHistoryList(CommandLine &Cmd);
APT_PUBLIC bool DoHistoryRedo(CommandLine &Cmd);
APT_PUBLIC bool DoHistoryRollback(CommandLine &Cmd);
APT_PUBLIC bool DoHistoryUndo(CommandLine &Cmd);
namespace APT::Internal
{
using namespace History;
/**
* Flatten the changes contained within a history entry.
*
* This function extracts and returns a flat list of all changes
* from the given entry, preserving their order if applicable.
*
* @param entry A history entry containing a map of changes.
* @return A vector containing all individual changes from the entry.
*/
std::vector<Change> FlattenChanges(const Entry &entry);
/**
* Invert a change.
*
* This function inverts a change's effective action and version
* such that a change followed by its inverse has no effective change.
*
* @param change A transactional change.
* @return The given change's inverse.
*/
Change InvertChange(const Change &change);
} // namespace APT::Internal
#endif
|