]> git.sur5r.net Git - openldap/blob - include/srchpref.h
Fixed exit code processing. passwd.c never committed its password change
[openldap] / include / srchpref.h
1 /* $OpenLDAP$ */
2 /*
3  * Copyright 1998-2001 The OpenLDAP Foundation, Redwood City, California, USA
4  * All rights reserved.
5  *
6  * Redistribution and use in source and binary forms, with or without
7  * modification, are permitted only as authorized by the OpenLDAP
8  * Public License.  A copy of this license is available at
9  * http://www.OpenLDAP.org/license.html or in file LICENSE in the
10  * top-level directory of the distribution.
11  */
12 /* Portions
13  * Copyright (c) 1993, 1994 Regents of the University of Michigan.
14  * All rights reserved.
15  *
16  * Redistribution and use in source and binary forms are permitted
17  * provided that this notice is preserved and that due credit is given
18  * to the University of Michigan at Ann Arbor. The name of the University
19  * may not be used to endorse or promote products derived from this
20  * software without specific prior written permission. This software
21  * is provided ``as is'' without express or implied warranty.
22  *
23  * searchpref.h:  display template library defines
24  * 16 May 1994 by Gordon Good
25  */
26
27 /* DEPRECATED DEPRECATED DEPRECATED DEPRECATED DEPRECATED */
28
29 #ifndef _SRCHPREF_H
30 #define _SRCHPREF_H
31
32 #include <ldap_cdefs.h>
33
34 LDAP_BEGIN_DECL
35
36 struct ldap_searchattr {
37         char                            *sa_attrlabel;
38         char                            *sa_attr;
39                                         /* max 32 matchtypes for now */
40         unsigned long                   sa_matchtypebitmap;
41         char                            *sa_selectattr;
42         char                            *sa_selecttext;
43         struct ldap_searchattr          *sa_next;
44 };
45
46 struct ldap_searchmatch {
47         char                            *sm_matchprompt;
48         char                            *sm_filter;
49         struct ldap_searchmatch         *sm_next;
50 };
51
52 struct ldap_searchobj {
53         char                            *so_objtypeprompt;
54         unsigned long                   so_options;
55         char                            *so_prompt;
56         short                           so_defaultscope;
57         char                            *so_filterprefix;
58         char                            *so_filtertag;
59         char                            *so_defaultselectattr;
60         char                            *so_defaultselecttext;
61         struct ldap_searchattr          *so_salist;
62         struct ldap_searchmatch         *so_smlist;
63         struct ldap_searchobj           *so_next;
64 };
65
66 /*
67  * global search object options
68  */
69 #define LDAP_SEARCHOBJ_OPT_INTERNAL     0x00000001
70
71 #define LDAP_IS_SEARCHOBJ_OPTION_SET( so, option )      \
72         (((so)->so_options & (option) ) != 0 )
73
74 #define LDAP_SEARCHPREF_VERSION_ZERO    0
75 #define LDAP_SEARCHPREF_VERSION         1
76
77 #define LDAP_SEARCHPREF_ERR_VERSION     1
78 #define LDAP_SEARCHPREF_ERR_MEM         2
79 #define LDAP_SEARCHPREF_ERR_SYNTAX      3
80 #define LDAP_SEARCHPREF_ERR_FILE        4
81
82
83 LDAP_F( int )
84 ldap_init_searchprefs LDAP_P(( char *file,
85         struct ldap_searchobj **solistp ));
86
87 LDAP_F( int )
88 ldap_init_searchprefs_buf LDAP_P(( char *buf,
89         ber_len_t buflen,
90         struct ldap_searchobj **solistp ));
91
92 LDAP_F( void )
93 ldap_free_searchprefs LDAP_P(( struct ldap_searchobj *solist ));
94
95 LDAP_F( struct ldap_searchobj * )
96 ldap_first_searchobj LDAP_P(( struct ldap_searchobj *solist ));
97
98 LDAP_F( struct ldap_searchobj * )
99 ldap_next_searchobj LDAP_P(( struct ldap_searchobj *sollist,
100         struct ldap_searchobj *so ));
101
102
103 LDAP_END_DECL
104
105 #endif /* _SRCHPREF_H */