1 /**
2  * Windows API header module
3  *
4  * RPC Name Service (RpcNs APIs)
5  *
6  * Translated from MinGW Windows headers
7  *
8  * License: $(LINK2 http://www.boost.org/LICENSE_1_0.txt, Boost License 1.0)
9  * Source: $(DRUNTIMESRC core/sys/windows/_rpcnsi.d)
10  */
11 module core.sys.windows.rpcnsi;
12 version (Windows):
13 
14 version (ANSI) {} else version = Unicode;
15 pragma(lib, "rpcns4");
16 
17 import core.sys.windows.basetyps, core.sys.windows.rpcdcep, core.sys.windows.rpcnsi, core.sys.windows.rpcdce,
18   core.sys.windows.w32api;
19 import core.sys.windows.windef;  // for HANDLE
20 
21 mixin DECLARE_HANDLE!("RPC_NS_HANDLE");
22 
23 enum RPC_C_NS_SYNTAX_DEFAULT=0;
24 enum RPC_C_NS_SYNTAX_DCE=3;
25 enum RPC_C_PROFILE_DEFAULT_ELT=0;
26 enum RPC_C_PROFILE_ALL_ELT=1;
27 enum RPC_C_PROFILE_MATCH_BY_IF=2;
28 enum RPC_C_PROFILE_MATCH_BY_MBR=3;
29 enum RPC_C_PROFILE_MATCH_BY_BOTH=4;
30 enum RPC_C_NS_DEFAULT_EXP_AGE=-1;
31 
32 extern (Windows) {
33     RPC_STATUS RpcNsBindingExportA(uint, ubyte*, RPC_IF_HANDLE,
34       RPC_BINDING_VECTOR*, UUID_VECTOR*);
35     RPC_STATUS RpcNsBindingUnexportA(uint, ubyte*, RPC_IF_HANDLE,
36       UUID_VECTOR*);
37     RPC_STATUS RpcNsBindingLookupBeginA(uint, ubyte*, RPC_IF_HANDLE, UUID*,
38       uint, RPC_NS_HANDLE*);
39     RPC_STATUS RpcNsBindingLookupNext(RPC_NS_HANDLE, RPC_BINDING_VECTOR**);
40     RPC_STATUS RpcNsBindingLookupDone(RPC_NS_HANDLE*);
41     RPC_STATUS RpcNsGroupDeleteA(uint, ubyte*);
42     RPC_STATUS RpcNsGroupMbrAddA(uint, ubyte*, uint, ubyte*);
43     RPC_STATUS RpcNsGroupMbrRemoveA(uint, ubyte*, uint, ubyte*);
44     RPC_STATUS RpcNsGroupMbrInqBeginA(uint, ubyte*, uint, RPC_NS_HANDLE*);
45     RPC_STATUS RpcNsGroupMbrInqNextA(RPC_NS_HANDLE, ubyte**);
46     RPC_STATUS RpcNsGroupMbrInqDone(RPC_NS_HANDLE*);
47     RPC_STATUS RpcNsProfileDeleteA(uint, ubyte*);
48     RPC_STATUS RpcNsProfileEltAddA(uint, ubyte*, RPC_IF_ID*, uint, ubyte*,
49       uint, ubyte*);
50     RPC_STATUS RpcNsProfileEltRemoveA(uint, ubyte*, RPC_IF_ID*, uint, ubyte*);
51     RPC_STATUS RpcNsProfileEltInqBeginA(uint, ubyte*, uint, RPC_IF_ID*, uint,
52       uint, ubyte*, RPC_NS_HANDLE*);
53     RPC_STATUS RpcNsProfileEltInqNextA(RPC_NS_HANDLE, RPC_IF_ID*, ubyte**,
54       uint*, ubyte**);
55     RPC_STATUS RpcNsProfileEltInqDone(RPC_NS_HANDLE*);
56     RPC_STATUS RpcNsEntryObjectInqNext(RPC_NS_HANDLE, UUID*);
57     RPC_STATUS RpcNsEntryObjectInqDone(RPC_NS_HANDLE*);
58     RPC_STATUS RpcNsEntryExpandNameA(uint, ubyte*, ubyte**);
59     RPC_STATUS RpcNsMgmtBindingUnexportA(uint, ubyte*, RPC_IF_ID*, uint,
60       UUID_VECTOR*);
61     RPC_STATUS RpcNsMgmtEntryCreateA(uint, ubyte*);
62     RPC_STATUS RpcNsMgmtEntryDeleteA(uint, ubyte*);
63     RPC_STATUS RpcNsMgmtEntryInqIfIdsA(uint, ubyte*, RPC_IF_ID_VECTOR**);
64     RPC_STATUS RpcNsMgmtHandleSetExpAge(RPC_NS_HANDLE, uint);
65     RPC_STATUS RpcNsMgmtInqExpAge(uint*);
66     RPC_STATUS RpcNsMgmtSetExpAge(uint);
67     RPC_STATUS RpcNsBindingImportNext(RPC_NS_HANDLE, RPC_BINDING_HANDLE*);
68     RPC_STATUS RpcNsBindingImportDone(RPC_NS_HANDLE*);
69     RPC_STATUS RpcNsBindingSelect(RPC_BINDING_VECTOR*, RPC_BINDING_HANDLE*);
70 
71 version (Unicode) {
72 } else {
73     RPC_STATUS RpcNsEntryObjectInqBeginA(uint, ubyte*, RPC_NS_HANDLE*);
74     RPC_STATUS RpcNsBindingImportBeginA(uint, ubyte*, RPC_IF_HANDLE, UUID*,
75       RPC_NS_HANDLE*);
76 }
77 
78     RPC_STATUS RpcNsBindingExportW(uint, ushort*, RPC_IF_HANDLE,
79       RPC_BINDING_VECTOR*, UUID_VECTOR*);
80     RPC_STATUS RpcNsBindingUnexportW(uint, ushort*, RPC_IF_HANDLE,
81       UUID_VECTOR*);
82     RPC_STATUS RpcNsBindingLookupBeginW(uint, ushort*, RPC_IF_HANDLE, UUID*,
83       uint, RPC_NS_HANDLE*);
84     RPC_STATUS RpcNsGroupDeleteW(uint, ushort*);
85     RPC_STATUS RpcNsGroupMbrAddW(uint, ushort*, uint, ushort*);
86     RPC_STATUS RpcNsGroupMbrRemoveW(uint, ushort*, uint, ushort*);
87     RPC_STATUS RpcNsGroupMbrInqBeginW(uint, ushort*, uint, RPC_NS_HANDLE*);
88     RPC_STATUS RpcNsGroupMbrInqNextW(RPC_NS_HANDLE, ushort**);
89     RPC_STATUS RpcNsProfileDeleteW(uint, ushort*);
90     RPC_STATUS RpcNsProfileEltAddW(uint, ushort*, RPC_IF_ID*, uint, ushort*,
91       uint, ushort*);
92     RPC_STATUS RpcNsProfileEltRemoveW(uint, ushort*, RPC_IF_ID*, uint,
93       ushort*);
94     RPC_STATUS RpcNsProfileEltInqBeginW(uint, ushort*, uint, RPC_IF_ID*,
95       uint, uint, ushort*, RPC_NS_HANDLE*);
96     RPC_STATUS RpcNsProfileEltInqNextW(RPC_NS_HANDLE, RPC_IF_ID*, ushort**,
97       uint*, ushort**);
98     RPC_STATUS RpcNsEntryObjectInqBeginW(uint, ushort*, RPC_NS_HANDLE*);
99     RPC_STATUS RpcNsEntryExpandNameW(uint, ushort*, ushort**);
100     RPC_STATUS RpcNsMgmtBindingUnexportW(uint, ushort*, RPC_IF_ID*, uint,
101       UUID_VECTOR*);
102     RPC_STATUS RpcNsMgmtEntryCreateW(uint, ushort*);
103     RPC_STATUS RpcNsMgmtEntryDeleteW(uint, ushort*);
104     RPC_STATUS RpcNsMgmtEntryInqIfIdsW(uint, ushort , RPC_IF_ID_VECTOR**);
105     RPC_STATUS RpcNsBindingImportBeginW(uint, ushort*, RPC_IF_HANDLE, UUID*,
106       RPC_NS_HANDLE*);
107 }
108 
109 version (Unicode) {
110     alias RpcNsBindingLookupBeginW RpcNsBindingLookupBegin;
111     alias RpcNsBindingImportBeginW RpcNsBindingImportBegin;
112     alias RpcNsBindingExportW RpcNsBindingExport;
113     alias RpcNsBindingUnexportW RpcNsBindingUnexport;
114     alias RpcNsGroupDeleteW RpcNsGroupDelete;
115     alias RpcNsGroupMbrAddW RpcNsGroupMbrAdd;
116     alias RpcNsGroupMbrRemoveW RpcNsGroupMbrRemove;
117     alias RpcNsGroupMbrInqBeginW RpcNsGroupMbrInqBegin;
118     alias RpcNsGroupMbrInqNextW RpcNsGroupMbrInqNext;
119     alias RpcNsEntryExpandNameW RpcNsEntryExpandName;
120     alias RpcNsEntryObjectInqBeginW RpcNsEntryObjectInqBegin;
121     alias RpcNsMgmtBindingUnexportW RpcNsMgmtBindingUnexport;
122     alias RpcNsMgmtEntryCreateW RpcNsMgmtEntryCreate;
123     alias RpcNsMgmtEntryDeleteW RpcNsMgmtEntryDelete;
124     alias RpcNsMgmtEntryInqIfIdsW RpcNsMgmtEntryInqIfIds;
125     alias RpcNsProfileDeleteW RpcNsProfileDelete;
126     alias RpcNsProfileEltAddW RpcNsProfileEltAdd;
127     alias RpcNsProfileEltRemoveW RpcNsProfileEltRemove;
128     alias RpcNsProfileEltInqBeginW RpcNsProfileEltInqBegin;
129     alias RpcNsProfileEltInqNextW RpcNsProfileEltInqNext;
130 } else {
131     alias RpcNsBindingLookupBeginA RpcNsBindingLookupBegin;
132     alias RpcNsBindingImportBeginA RpcNsBindingImportBegin;
133     alias RpcNsBindingExportA RpcNsBindingExport;
134     alias RpcNsBindingUnexportA RpcNsBindingUnexport;
135     alias RpcNsGroupDeleteA RpcNsGroupDelete;
136     alias RpcNsGroupMbrAddA RpcNsGroupMbrAdd;
137     alias RpcNsGroupMbrRemoveA RpcNsGroupMbrRemove;
138     alias RpcNsGroupMbrInqBeginA RpcNsGroupMbrInqBegin;
139     alias RpcNsGroupMbrInqNextA RpcNsGroupMbrInqNext;
140     alias RpcNsEntryExpandNameA RpcNsEntryExpandName;
141     alias RpcNsEntryObjectInqBeginA RpcNsEntryObjectInqBegin;
142     alias RpcNsMgmtBindingUnexportA RpcNsMgmtBindingUnexport;
143     alias RpcNsMgmtEntryCreateA RpcNsMgmtEntryCreate;
144     alias RpcNsMgmtEntryDeleteA RpcNsMgmtEntryDelete;
145     alias RpcNsMgmtEntryInqIfIdsA RpcNsMgmtEntryInqIfIds;
146     alias RpcNsProfileDeleteA RpcNsProfileDelete;
147     alias RpcNsProfileEltAddA RpcNsProfileEltAdd;
148     alias RpcNsProfileEltRemoveA RpcNsProfileEltRemove;
149     alias RpcNsProfileEltInqBeginA RpcNsProfileEltInqBegin;
150     alias RpcNsProfileEltInqNextA RpcNsProfileEltInqNext;
151 }