1 /* -*- Mode: C; indent-tabs-mode: t; c-basic-offset: 4; tab-width: 4 -*- */
4 Copyright (C) 2004 Sebastien Granjoux
6 This program is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 2 of the License, or
9 (at your option) any later version.
11 This program is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
16 You should have received a copy of the GNU General Public License
17 along with this program; if not, write to the Free Software
18 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
26 typedef struct _NPWHeader NPWHeader
;
27 typedef struct _NPWHeaderList NPWHeaderList
;
29 NPWHeader
* npw_header_new (void);
30 void npw_header_free (NPWHeader
* self
);
32 void npw_header_set_name (NPWHeader
* this, const gchar
* name
, gint lang
);
33 const gchar
* npw_header_get_name (const NPWHeader
* self
);
35 void npw_header_set_filename (NPWHeader
* this, const gchar
* filename
);
36 const gchar
* npw_header_get_filename (const NPWHeader
* self
);
38 void npw_header_set_category (NPWHeader
* this, const gchar
* category
);
39 const gchar
* npw_header_get_category(const NPWHeader
* self
);
41 void npw_header_set_description (NPWHeader
* this, const gchar
* description
, gint lang
);
42 const gchar
* npw_header_get_description (const NPWHeader
* self
);
44 void npw_header_set_iconfile (NPWHeader
* this, const gchar
* confile
);
45 const gchar
* npw_header_get_iconfile (const NPWHeader
* self
);
47 void npw_header_set_order (NPWHeader
* this, const gchar
*order
);
48 const guint
npw_header_get_order (const NPWHeader
* self
);
50 void npw_header_add_required_program (NPWHeader
* self
, const gchar
* program
);
52 /* Returns list of missing programs, or NULL if none is missing
53 * Only the glist should be freed, not the strings within
55 GList
* npw_header_check_required_programs (NPWHeader
* self
);
57 void npw_header_add_required_package (NPWHeader
* self
, const gchar
* package
);
59 /* Returns list of missing packages, or NULL if none is missing
60 * Only the glist should be freed, not the strings within
62 GList
* npw_header_check_required_packages (NPWHeader
* self
);
65 GList
* npw_header_list_new (void);
66 void npw_header_list_free (GList
* list
);
67 GList
* npw_header_list_insert_header (GList
*list
, NPWHeader
*header
);
68 NPWHeader
* npw_header_list_find_header (GList
*list
, NPWHeader
*header
);