]>
git.ipfire.org Git - thirdparty/cups.git/blob - cgi-bin/help-index.h
fd587b0e4c0a1248972e14c1a180c274265f6b1b
4 * On-line help index definitions for the Common UNIX Printing System (CUPS).
6 * Copyright 1997-2006 by Easy Software Products.
8 * These coded instructions, statements, and computer programs are the
9 * property of Easy Software Products and are protected by Federal
10 * copyright law. Distribution and use rights are outlined in the file
11 * "LICENSE.txt" which should have been included with this file. If this
12 * file is missing or damaged please contact Easy Software Products
15 * Attn: CUPS Licensing Information
16 * Easy Software Products
17 * 44141 Airport View Drive, Suite 204
18 * Hollywood, Maryland 20636 USA
20 * Voice: (301) 373-9600
21 * EMail: cups-info@cups.org
22 * WWW: http://www.cups.org
25 #ifndef _CUPS_HELP_INDEX_H_
26 # define _CUPS_HELP_INDEX_H_
29 * Include necessary headers...
32 # include <cups/array.h>
39 typedef struct /**** Help node structure... ****/
41 char *filename
; /* Filename, relative to help dir */
42 char *section
; /* Section name (NULL if none) */
43 char *anchor
; /* Anchor name (NULL if none) */
44 char *text
; /* Text in anchor */
45 time_t mtime
; /* Last modification time */
46 off_t offset
; /* Offset in file */
47 size_t length
; /* Length in bytes */
48 int score
; /* Search score */
51 typedef struct /**** Help index structure ****/
53 int search
; /* 1 = search index, 0 = normal */
54 cups_array_t
*nodes
; /* Nodes sorted by filename */
55 cups_array_t
*sorted
; /* Nodes sorted by score + text */
63 extern void helpDeleteIndex(help_index_t
*hi
);
64 extern help_node_t
*helpFindNode(help_index_t
*hi
, const char *filename
,
66 extern help_index_t
*helpLoadIndex(const char *hifile
, const char *directory
);
67 extern int helpSaveIndex(help_index_t
*hi
, const char *hifile
);
68 extern help_index_t
*helpSearchIndex(help_index_t
*hi
, const char *query
,
70 const char *filename
);
73 #endif /* !_CUPS_HELP_INDEX_H_ */