]>
git.saurik.com Git - apt.git/blob - methods/rsh.h
c3f3258e96ed1401de5a310d791574cd33053044
1 // -*- mode: cpp; mode: fold -*-
2 // Description /*{{{*/// $Id: rsh.h,v 1.2 2001/02/20 07:03:18 jgg Exp $
3 // $Id: rsh.h,v 1.2 2001/02/20 07:03:18 jgg Exp $
4 /* ######################################################################
6 RSH method - Transfer files via rsh compatible program
8 ##################################################################### */
14 #include <apt-pkg/strutl.h>
15 #include <apt-pkg/md5.h>
16 #include <apt-pkg/acquire-method.h>
17 #include <apt-pkg/fileutl.h>
27 // Private helper functions
28 bool ReadLine(string
&Text
);
35 bool WriteMsg(string
&Text
,bool Sync
,const char *Fmt
,...);
36 bool Connect(string Host
, string User
);
37 bool Comp(URI Other
) {return Other
.Host
== ServerName
.Host
&& Other
.Port
== ServerName
.Port
;};
44 bool Size(const char *Path
,unsigned long &Size
);
45 bool ModTime(const char *Path
, time_t &Time
);
46 bool Get(const char *Path
,FileFd
&To
,unsigned long Resume
,
47 MD5Summation
&MD5
,bool &Missing
, unsigned long Size
);
53 class RSHMethod
: public pkgAcqMethod
55 virtual bool Fetch(FetchItem
*Itm
);
59 static string FailFile
;
61 static time_t FailTime
;
62 static void SigTerm(int);