]> cygwin.com Git - cygwin-apps/setup.git/blob - cygpackage.h
2001-11-30 Robert Collins <rbtcollins@hotmail.com>
[cygwin-apps/setup.git] / cygpackage.h
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 /* This is a cygwin specific package class, that should be able to
17 * arbitrate acceess to cygwin binary packages amd cygwin source packages
18 */
19
20 #ifndef _CYGPACKAGE_H_
21 #define _CYGPACKAGE_H_
22
23 class cygpackage:public packageversion
24 {
25 public:
26 virtual const char *Name ();
27 virtual const char *Vendor_version ();
28 virtual const char *Package_version ();
29 virtual char const *Canonical_version ();
30 virtual package_status_t Status ()
31 {
32 return status;
33 };
34 virtual package_type_t Type ()
35 {
36 return type;
37 };
38 void set_sdesc (char const *);
39 void set_ldesc (char const *);
40 virtual char const *SDesc ()
41 {
42 return sdesc;
43 };
44 virtual char const *LDesc ()
45 {
46 return ldesc;
47 };
48 virtual void uninstall ();
49
50
51 /* pass the name of the package when constructing */
52 cygpackage (const char *);
53 cygpackage (const char *, const char *, size_t, const char *,
54 package_status_t, package_type_t);
55 void set_canonical_version (char const *);
56
57
58 virtual ~ cygpackage ();
59 /* TODO: we should probably return a metaclass - file name & path & size & type
60 - ie doc/script/binary
61 */
62 virtual const char *getfirstfile ();
63 virtual const char *getnextfile ();
64 private:
65 void destroy ();
66 char *name;
67 char *vendor;
68 char *packagev;
69 char *canonical;
70 char *fn;
71 char *sdesc, *ldesc;
72 char getfilenamebuffer[_MAX_PATH];
73
74 // package_stability_t stability;
75 package_status_t status;
76 package_type_t type;
77
78 io_stream *listdata, *listfile;
79 size_t filesize;
80 };
81
82 #endif /* _CYGPACKAGE_H_ */
This page took 0.104207 seconds and 5 git commands to generate.