root/branches/3.00/src/cygpackage.h

Revision 644, 2.3 kB (checked in by fujii, 3 years ago)

Add new netinstall source.

Line 
1 /*
2  * Copyright (c) 2001, Robert Collins.
3  *
4  *     This program is free software; you can redistribute it and/or modify
5  *     it under the terms of the GNU General Public License as published by
6  *     the Free Software Foundation; either version 2 of the License, or
7  *     (at your option) any later version.
8  *
9  *     A copy of the GNU General Public License can be found at
10  *     http://www.gnu.org/
11  *
12  * Written by Robert Collins  <rbtcollins@hotmail.com>
13  *
14  */
15
16 #ifndef SETUP_CYGPACKAGE_H
17 #define SETUP_CYGPACKAGE_H
18
19 /* This is a cygwin specific package class, that should be able to
20  * arbitrate acceess to cygwin binary packages amd cygwin source packages
21  */
22
23 #include "String++.h"
24 /* for _MAX_PATH */
25 #include "win32.h"
26
27 #include "package_version.h"
28
29 class cygpackage:public _packageversion
30 {
31 public:
32   virtual String const Name ();
33   virtual String const Vendor_version ();
34   virtual String const Package_version ();
35   virtual String const Canonical_version ();
36   virtual package_status_t Status ()
37   {
38     return status;
39   };
40   virtual package_type_t Type ()
41   {
42     return type;
43   };
44   virtual void set_sdesc (String const &);
45   virtual void set_ldesc (String const &);
46   virtual String const SDesc ()
47   {
48     return sdesc;
49   };
50   virtual String const LDesc ()
51   {
52     return ldesc;
53   };
54   virtual void uninstall ();
55
56
57   /* pass the name of the package when constructing */
58   void setCanonicalVersion (String const &);
59
60
61   virtual ~ cygpackage ();
62   /* TODO: we should probably return a metaclass - file name & path & size & type
63      - ie doc/script/binary
64    */
65   virtual String const getfirstfile ();
66   virtual String const getnextfile ();
67
68   /* pass the name of the package when constructing */
69   static packageversion createInstance (String const &);
70   static packageversion createInstance (String const &, String const &,
71                                         size_t const, String const &,
72                                         package_status_t const,
73                                         package_type_t const);
74 private:
75   cygpackage ();
76   void destroy ();
77   String name;
78   String vendor;
79   String packagev;
80   String canonical;
81   String fn;
82   String sdesc, ldesc;
83   char getfilenamebuffer[_MAX_PATH];
84
85 //  package_stability_t stability;
86   package_status_t status;
87   package_type_t type;
88
89   io_stream *listdata, *listfile;
90   size_t filesize;
91 };
92
93 #endif /* SETUP_CYGPACKAGE_H */
Note: See TracBrowser for help on using the browser.