aptmethod.h 1.15 KB
Newer Older
Bernhard Link's avatar
Bernhard Link committed
1 2
#ifndef REPREPRO_APTMETHOD_H
#define REPREPRO_APTMETHOD_H
3

4 5
#ifndef REPREPRO_DATABASE_H
#include "database.h"
6
#endif
7 8 9
#ifndef REPREPRO_CHECKSUMS_H
#include "checksums.h"
#endif
10

11 12 13
struct aptmethodrun;
struct aptmethod;

14 15
enum queue_action { qa_abort, qa_got, qa_error };

16
typedef retvalue queue_callback(enum queue_action, void *, void *, const char * /*uri*/, const char * /*gotfilename*/, const char * /*wantedfilename*/, /*@null@*/const struct checksums *, const char * /*methodname*/);
17

18 19
retvalue aptmethod_initialize_run(/*@out@*/struct aptmethodrun **);
retvalue aptmethod_newmethod(struct aptmethodrun *, const char * /*uri*/, const char * /*fallbackuri*/, const struct strlist * /*config*/, /*@out@*/struct aptmethod **);
20

21 22
retvalue aptmethod_enqueue(struct aptmethod *, const char * /*origfile*/, /*@only@*/char */*destfile*/, queue_callback *, void *, void *);
retvalue aptmethod_enqueueindex(struct aptmethod *, const char * /*suite*/, const char * /*origfile*/, const char *, const char * /*destfile*/, const char *, queue_callback *, void *, void *);
23

24
retvalue aptmethod_download(struct aptmethodrun *);
25
retvalue aptmethod_shutdown(/*@only@*/struct aptmethodrun *);
26 27

#endif