annotate win32/winber.d @ 1:4a9dcbd9e54f

-files of 0.13 beta -fixes so that it now compiles with the current dmd version
author marton@basel.hu
date Tue, 05 Apr 2011 20:44:01 +0200
parents
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
1 /***********************************************************************\
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
2 * winber.d *
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
3 * *
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
4 * Windows API header module *
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
5 * *
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
6 * Translated from MinGW Windows headers *
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
7 * by Stewart Gordon *
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
8 * *
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
9 * Placed into public domain *
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
10 \***********************************************************************/
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
11 module win32.winber;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
12
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
13 /* Comment from MinGW
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
14 winber.h - Header file for the Windows LDAP Basic Encoding Rules API
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
15
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
16 Written by Filip Navara <xnavara@volny.cz>
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
17
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
18 References:
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
19 The C LDAP Application Program Interface
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
20 http://www.watersprings.org/pub/id/draft-ietf-ldapext-ldap-c-api-05.txt
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
21
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
22 Lightweight Directory Access Protocol Reference
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
23 http://msdn.microsoft.com/library/en-us/netdir/ldap/ldap_reference.asp
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
24
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
25 This library is distributed in the hope that it will be useful,
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
26 but WITHOUT ANY WARRANTY; without even the implied warranty of
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
27 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
28 */
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
29
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
30 /* Opaque structure
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
31 * http://msdn.microsoft.com/library/en-us/ldap/ldap/berelement.asp
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
32 */
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
33 struct BerElement;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
34
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
35 alias int ber_int_t, ber_slen_t;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
36 alias uint ber_uint_t, ber_len_t, ber_tag_t;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
37
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
38 align(4):
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
39 struct BerValue {
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
40 ber_len_t bv_len;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
41 char* bv_val;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
42 }
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
43 alias BerValue LDAP_BERVAL, BERVAL;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
44 alias BerValue* PLDAP_BERVAL, PBERVAL;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
45
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
46 const ber_tag_t
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
47 LBER_ERROR = -1,
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
48 LBER_DEFAULT = -1,
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
49 LBER_USE_DER = 1;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
50
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
51 /* FIXME: In MinGW, these are WINBERAPI == DECLSPEC_IMPORT. Linkage
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
52 * attribute?
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
53 */
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
54 extern (C) {
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
55 BerElement* ber_init(BerValue*);
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
56 int ber_printf(BerElement*, char*, ...);
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
57 int ber_flatten(BerElement*, BerValue**);
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
58 ber_tag_t ber_scanf(BerElement*, char*, ...);
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
59 ber_tag_t ber_peek_tag(BerElement*, ber_len_t*);
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
60 ber_tag_t ber_skip_tag(BerElement*, ber_len_t*);
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
61 ber_tag_t ber_first_element(BerElement*, ber_len_t*, char**);
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
62 ber_tag_t ber_next_element(BerElement*, ber_len_t*, char*);
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
63 void ber_bvfree(BerValue*);
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
64 void ber_bvecfree(BerValue**);
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
65 void ber_free(BerElement*, int);
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
66 BerValue* ber_bvdup(BerValue*);
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
67 BerElement* ber_alloc_t(int);
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
68 }