summaryrefslogtreecommitdiffstats
path: root/apt-private/private-download.h
blob: d829e8b24b7d31bdbf13eddebb45984b5e8b5017 (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
#ifndef APT_PRIVATE_DOWNLOAD_H
#define APT_PRIVATE_DOWNLOAD_H

#include <apt-pkg/acquire.h>
#include <apt-pkg/macros.h>

#include <apt-private/acqprogress.h>

#include <string>
#include <vector>

// Check if all files in the fetcher are authenticated
bool CheckAuth(pkgAcquire& Fetcher, bool const PromptUser);

// show a authentication warning prompt and return true if the system
// should continue
bool AuthPrompt(std::vector<std::string> const &UntrustedList, bool const PromptUser);

APT_PUBLIC bool AcquireRun(pkgAcquire &Fetcher, int const PulseInterval, bool * const Failure, bool * const TransientNetworkFailure);

bool CheckFreeSpaceBeforeDownload(std::string const &Dir, unsigned long long FetchBytes);

class APT_PUBLIC aptAcquireWithTextStatus : public pkgAcquire
{
   AcqTextStatus Stat;
public:
   aptAcquireWithTextStatus();
};

class CommandLine;

APT_PUBLIC bool DoDownload(CommandLine &CmdL);
APT_PUBLIC bool DoChangelog(CommandLine &CmdL);

APT_PUBLIC bool DoClean(CommandLine &CmdL);
APT_PUBLIC bool DoAutoClean(CommandLine &CmdL);

#endif