' ########################################################################################
' Microsoft Windows
' File: RpcNsi.inc
' Contents: Types and function definitions to use the Name Service Independent APIs.
' Copyright (c) 2011 Jos? Roca
' Portions Copyright (c) Microsoft Corporation.
' All Rights Reserved.
' THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER
' EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED WARRANTIES OF
' MERCHANTABILITY AND/OR FITNESS FOR A PARTICULAR PURPOSE.
' ########################################################################################
#IF NOT %DEF(PBX_RpcNsi_PBI)
#DEFINE PBX_RpcNsi_PBI
%EQUATE `RPCNSI_INC = 1
#INCLUDE ONCE "Legacy/Network/RpcDce.inc"
'typedef void * RPC_NS_HANDLE;
%EQUATE `RPC_C_NS_SYNTAX_DEFAULT = 0
%EQUATE `RPC_C_NS_SYNTAX_DCE = 3
%EQUATE `RPC_C_PROFILE_DEFAULT_ELT = 0
%EQUATE `RPC_C_PROFILE_ALL_ELT = 1
%EQUATE `RPC_C_PROFILE_ALL_ELTS = %RPC_C_PROFILE_ALL_ELT
%EQUATE `RPC_C_PROFILE_MATCH_BY_IF = 2
%EQUATE `RPC_C_PROFILE_MATCH_BY_MBR = 3
%EQUATE `RPC_C_PROFILE_MATCH_BY_BOTH = 4
%EQUATE `RPC_C_NS_DEFAULT_EXP_AGE = -1
'/* Server APIs */
DECLARE FUNCTION RpcNsBindingExportA LIB "rpcns4.dll" ALIAS "RpcNsBindingExportA" ( BYVAL EntryNameSyntax AS QUAD , BYREF EntryName AS ASCIIZ , BYVAL IfSpec AS QUAD , BYREF BindingVec AS RPC_BINDING_VECTOR , BYREF ObjectUuidVec AS UUID_VECTOR ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsBindingExportW LIB "rpcns4.dll" ALIAS "RpcNsBindingExportW" ( BYVAL EntryNameSyntax AS QUAD , BYVAL EntryName AS QUAD , BYVAL IfSpec AS QUAD , BYREF BindingVec AS RPC_BINDING_VECTOR , BYREF ObjectUuidVec AS UUID_VECTOR ) AS LONG ' RPC_STATUS
#IF %DEF(%UNICODE)
 MACRO RpcNsBindingExport = RpcNsBindingExportW
#ELSE
 MACRO RpcNsBindingExport = RpcNsBindingExportA
#ENDIF
DECLARE FUNCTION RpcNsBindingUnexportA LIB "rpcns4.dll" ALIAS "RpcNsBindingUnexportA" ( BYVAL EntryNameSyntax AS QUAD , BYREF EntryName AS ASCIIZ , BYVAL IfSpec AS QUAD , BYREF ObjectUuidVec AS UUID_VECTOR ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsBindingUnexportW LIB "rpcns4.dll" ALIAS "RpcNsBindingUnexportW" ( BYVAL EntryNameSyntax AS QUAD , BYVAL EntryName AS QUAD , BYVAL IfSpec AS QUAD , BYREF ObjectUuidVec AS UUID_VECTOR ) AS LONG ' RPC_STATUS
#IF %DEF(%UNICODE)
 MACRO RpcNsBindingUnexport = RpcNsBindingUnexportW
#ELSE
 MACRO RpcNsBindingUnexport = RpcNsBindingUnexportA
#ENDIF
'/* Server PnP APIs */
DECLARE FUNCTION RpcNsBindingExportPnPA LIB "rpcns4.dll" ALIAS "RpcNsBindingExportPnPA" ( BYVAL EntryNameSyntax AS QUAD , BYREF EntryName AS ASCIIZ , BYVAL IfSpec AS QUAD , BYREF ObjectVector AS UUID_VECTOR ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsBindingExportPnPW LIB "rpcns4.dll" ALIAS "RpcNsBindingExportPnPW" ( BYVAL EntryNameSyntax AS QUAD , BYREF EntryName AS WSTRINGZ , BYVAL IfSpec AS QUAD , BYREF ObjectVector AS UUID_VECTOR ) AS LONG ' RPC_STATUS
#IF %DEF(%UNICODE)
 MACRO RpcNsBindingExportPnP = RpcNsBindingExportPnPW
#ELSE
 MACRO RpcNsBindingExportPnP = RpcNsBindingExportPnPA
#ENDIF
DECLARE FUNCTION RpcNsBindingUnexportPnPA LIB "rpcns4.dll" ALIAS "RpcNsBindingUnexportPnPA" ( BYVAL EntryNameSyntax AS QUAD , BYREF EntryName AS ASCIIZ , BYVAL IfSpec AS QUAD , BYREF ObjectVector AS UUID_VECTOR ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsBindingUnexportPnPW LIB "rpcns4.dll" ALIAS "RpcNsBindingUnexportPnPW" ( BYVAL EntryNameSyntax AS QUAD , BYREF EntryName AS WSTRINGZ , BYVAL IfSpec AS QUAD , BYREF ObjectVector AS UUID_VECTOR ) AS LONG ' RPC_STATUS
#IF %DEF(%UNICODE)
 MACRO RpcNsBindingUnexportPnP = RpcNsBindingUnexportPnPW
#ELSE
 MACRO RpcNsBindingUnexportPnP = RpcNsBindingUnexportPnPA
#ENDIF
'/* Client APIs */
DECLARE FUNCTION RpcNsBindingLookupBeginA LIB "rpcns4.dll" ALIAS "RpcNsBindingLookupBeginA" ( BYVAL EntryNameSyntax AS QUAD , BYREF EntryName AS ASCIIZ , BYVAL IfSpec AS QUAD , BYREF ObjUuid AS GUID , BYVAL BindingMaxCount AS QUAD , BYREF LookupContext AS QUAD ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsBindingLookupBeginW LIB "rpcns4.dll" ALIAS "RpcNsBindingLookupBeginW" ( BYVAL EntryNameSyntax AS QUAD , BYREF EntryName AS WSTRINGZ , BYVAL IfSpec AS QUAD , BYREF ObjUuid AS GUID , BYVAL BindingMaxCount AS QUAD , BYREF LookupContext AS QUAD ) AS LONG ' RPC_STATUS
#IF %DEF(%UNICODE)
 MACRO RpcNsBindingLookupBegin = RpcNsBindingLookupBeginW
#ELSE
 MACRO RpcNsBindingLookupBegin = RpcNsBindingLookupBeginA
#ENDIF
DECLARE FUNCTION RpcNsBindingLookupNext LIB "rpcns4.dll" ALIAS "RpcNsBindingLookupNext" ( BYVAL LookupContext AS QUAD , BYREF BindingVec AS RPC_BINDING_VECTOR ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsBindingLookupDone LIB "rpcns4.dll" ALIAS "RpcNsBindingLookupDone" ( BYREF LookupContext AS QUAD ) AS LONG ' RPC_STATUS
'/* Group APIs */
DECLARE FUNCTION RpcNsGroupDeleteA LIB "rpcns4.dll" ALIAS "RpcNsGroupDeleteA" ( BYVAL GroupNameSyntax AS QUAD , BYREF GroupName AS ASCIIZ ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsGroupDeleteW LIB "rpcns4.dll" ALIAS "RpcNsGroupDeleteW" ( BYVAL GroupNameSyntax AS QUAD , BYREF GroupName AS WSTRINGZ ) AS LONG ' RPC_STATUS
#IF %DEF(%UNICODE)
 MACRO RpcNsGroupDelete = RpcNsGroupDeleteW
#ELSE
 MACRO RpcNsGroupDelete = RpcNsGroupDeleteA
#ENDIF
DECLARE FUNCTION RpcNsGroupMbrAddA LIB "rpcns4.dll" ALIAS "RpcNsGroupMbrAddA" ( BYVAL GroupNameSyntax AS QUAD , BYREF GroupName AS ASCIIZ , BYVAL MemberNameSyntax AS QUAD , BYREF MemberName AS ASCIIZ ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsGroupMbrAddW LIB "rpcns4.dll" ALIAS "RpcNsGroupMbrAddW" ( BYVAL GroupNameSyntax AS QUAD , BYREF GroupName AS WSTRINGZ , BYVAL MemberNameSyntax AS QUAD , BYREF MemberName AS ASCIIZ ) AS LONG ' RPC_STATUS
#IF %DEF(%UNICODE)
 MACRO RpcNsGroupMbrAdd = RpcNsGroupMbrAddW
#ELSE
 MACRO RpcNsGroupMbrAdd = RpcNsGroupMbrAddA
#ENDIF
DECLARE FUNCTION RpcNsGroupMbrRemoveA LIB "rpcns4.dll" ALIAS "RpcNsGroupMbrRemoveA" ( BYVAL GroupNameSyntax AS QUAD , BYREF GroupName AS ASCIIZ , BYVAL MemberNameSyntax AS QUAD , BYREF MemberName AS ASCIIZ ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsGroupMbrRemoveW LIB "rpcns4.dll" ALIAS "RpcNsGroupMbrRemoveW" ( BYVAL GroupNameSyntax AS QUAD , BYREF GroupName AS WSTRINGZ , BYVAL MemberNameSyntax AS QUAD , BYVAL MemberName AS QUAD ) AS LONG ' RPC_STATUS
#IF %DEF(%UNICODE)
 MACRO RpcNsGroupMbrRemove = RpcNsGroupMbrRemoveW
#ELSE
 MACRO RpcNsGroupMbrRemove = RpcNsGroupMbrRemoveA
#ENDIF
DECLARE FUNCTION RpcNsGroupMbrInqBeginA LIB "rpcns4.dll" ALIAS "RpcNsGroupMbrInqBeginA" ( BYVAL GroupNameSyntax AS QUAD , BYREF GroupName AS ASCIIZ , BYVAL MemberNameSyntax AS QUAD , BYREF InquiryContext AS QUAD ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsGroupMbrInqBeginW LIB "rpcns4.dll" ALIAS "RpcNsGroupMbrInqBeginW" ( BYVAL GroupNameSyntax AS QUAD , BYREF GroupName AS WSTRINGZ , BYVAL MemberNameSyntax AS QUAD , BYREF InquiryContext AS QUAD ) AS LONG ' RPC_STATUS
#IF %DEF(%UNICODE)
 MACRO RpcNsGroupMbrInqBegin = RpcNsGroupMbrInqBeginW
#ELSE
 MACRO RpcNsGroupMbrInqBegin = RpcNsGroupMbrInqBeginA
#ENDIF
DECLARE FUNCTION RpcNsGroupMbrInqNextA LIB "rpcns4.dll" ALIAS "RpcNsGroupMbrInqNextA" ( BYREF InquiryContext AS QUAD , BYREF MemberName AS QUAD ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsGroupMbrInqNextW LIB "rpcns4.dll" ALIAS "RpcNsGroupMbrInqNextW" ( BYREF InquiryContext AS QUAD , BYREF MemberName AS QUAD ) AS LONG ' RPC_STATUS
#IF %DEF(%UNICODE)
 MACRO RpcNsGroupMbrInqNext = RpcNsGroupMbrInqNextW
#ELSE
 MACRO RpcNsGroupMbrInqNext = RpcNsGroupMbrInqNextA
#ENDIF
DECLARE FUNCTION RpcNsGroupMbrInqDone LIB "rpcns4.dll" ALIAS "RpcNsGroupMbrInqDone" ( BYREF InquiryContext AS QUAD ) AS LONG ' RPC_STATUS
'/* Profile APIs */
DECLARE FUNCTION RpcNsProfileDeleteA LIB "rpcns4.dll" ALIAS "RpcNsProfileDeleteA" ( BYVAL ProfileNameSyntax AS QUAD , BYREF ProfileName AS ASCIIZ ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsProfileDeleteW LIB "rpcns4.dll" ALIAS "RpcNsProfileDeleteW" ( BYVAL ProfileNameSyntax AS QUAD , BYREF ProfileName AS WSTRINGZ ) AS LONG ' RPC_STATUS
#IF %DEF(%UNICODE)
 MACRO RpcNsProfileDelete = RpcNsProfileDeleteW
#ELSE
 MACRO RpcNsProfileDelete = RpcNsProfileDeleteA
#ENDIF
DECLARE FUNCTION RpcNsProfileEltAddA LIB "rpcns4.dll" ALIAS "RpcNsProfileEltAddA" ( BYVAL ProfileNameSyntax AS QUAD , BYREF ProfileName AS ASCIIZ , BYVAL IfId AS QUAD , BYVAL MemberNameSyntax AS QUAD , BYREF MemberName AS ASCIIZ , BYVAL Priority AS QUAD , BYREF Annotation AS ASCIIZ ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsProfileEltAddW LIB "rpcns4.dll" ALIAS "RpcNsProfileEltAddW" ( BYVAL ProfileNameSyntax AS QUAD , BYREF ProfileName AS WSTRINGZ , BYVAL IfId AS QUAD , BYVAL MemberNameSyntax AS QUAD , BYREF MemberName AS WSTRINGZ , BYVAL Priority AS QUAD , BYREF Annotation AS WSTRINGZ ) AS LONG ' RPC_STATUS
#IF %DEF(%UNICODE)
 MACRO RpcNsProfileEltAdd = RpcNsProfileEltAddW
#ELSE
 MACRO RpcNsProfileEltAdd = RpcNsProfileEltAddA
#ENDIF
DECLARE FUNCTION RpcNsProfileEltRemoveA LIB "rpcns4.dll" ALIAS "RpcNsProfileEltRemoveA" ( BYVAL ProfileNameSyntax AS QUAD , BYREF ProfileName AS ASCIIZ , BYVAL IfId AS QUAD , BYVAL MemberNameSyntax AS QUAD , BYREF MemberName AS ASCIIZ ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsProfileEltRemoveW LIB "rpcns4.dll" ALIAS "RpcNsProfileEltRemoveW" ( BYVAL ProfileNameSyntax AS QUAD , BYREF ProfileName AS WSTRINGZ , BYVAL IfId AS QUAD , BYVAL MemberNameSyntax AS QUAD , BYREF MemberName AS WSTRINGZ ) AS LONG ' RPC_STATUS
#IF %DEF(%UNICODE)
 MACRO RpcNsProfileEltRemove = RpcNsProfileEltRemoveW
#ELSE
 MACRO RpcNsProfileEltRemove = RpcNsProfileEltRemoveA
#ENDIF
DECLARE FUNCTION RpcNsProfileEltInqBeginA LIB "rpcns4.dll" ALIAS "RpcNsProfileEltInqBeginA" ( BYVAL ProfileNameSyntax AS QUAD , BYREF ProfileName AS ASCIIZ , BYVAL InquiryType AS QUAD , BYVAL IfId AS QUAD , BYVAL VersOption AS QUAD , BYVAL MemberNameSyntax AS QUAD , BYREF MemberName AS ASCIIZ , BYREF InquiryContext AS QUAD ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsProfileEltInqBeginW LIB "rpcns4.dll" ALIAS "RpcNsProfileEltInqBeginW" ( BYVAL ProfileNameSyntax AS QUAD , BYREF ProfileName AS WSTRINGZ , BYVAL InquiryType AS QUAD , BYVAL IfId AS QUAD , BYVAL VersOption AS QUAD , BYVAL MemberNameSyntax AS QUAD , BYREF MemberName AS WSTRINGZ , BYREF InquiryContext AS QUAD ) AS LONG ' RPC_STATUS
#IF %DEF(%UNICODE)
 MACRO RpcNsProfileEltInqBegin = RpcNsProfileEltInqBeginW
#ELSE
 MACRO RpcNsProfileEltInqBegin = RpcNsProfileEltInqBeginA
#ENDIF
DECLARE FUNCTION RpcNsProfileEltInqNextA LIB "rpcns4.dll" ALIAS "RpcNsProfileEltInqNextA" ( BYVAL InquiryContext AS QUAD , BYREF IfId AS QUAD , BYREF MemberName AS QUAD , BYREF Priority AS QUAD , BYREF Annotation AS QUAD ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsProfileEltInqNextW LIB "rpcns4.dll" ALIAS "RpcNsProfileEltInqNextW" ( BYVAL InquiryContext AS QUAD , BYREF IfId AS QUAD , BYREF MemberName AS QUAD , BYREF Priority AS QUAD , BYREF Annotation AS QUAD ) AS LONG ' RPC_STATUS
#IF %DEF(%UNICODE)
 MACRO RpcNsProfileEltInqNext = RpcNsProfileEltInqNextW
#ELSE
 MACRO RpcNsProfileEltInqNext = RpcNsProfileEltInqNextA
#ENDIF
DECLARE FUNCTION RpcNsProfileEltInqDone LIB "rpcns4.dll" ALIAS "RpcNsProfileEltInqDone" ( BYREF InquiryContext AS QUAD ) AS LONG ' RPC_STATUS
'/* Entry object APIs */
DECLARE FUNCTION RpcNsEntryObjectInqBeginA LIB "rpcns4.dll" ALIAS "RpcNsEntryObjectInqBeginA" ( BYVAL EntryNameSyntax AS QUAD , BYREF EntryName AS ASCIIZ , BYREF InquiryContext AS QUAD ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsEntryObjectInqBeginW LIB "rpcns4.dll" ALIAS "RpcNsEntryObjectInqBeginW" ( BYVAL EntryNameSyntax AS QUAD , BYVAL EntryName AS QUAD , BYREF InquiryContext AS QUAD ) AS LONG ' RPC_STATUS
#IF %DEF(%UNICODE)
 MACRO RpcNsEntryObjectInqBegin = RpcNsEntryObjectInqBeginW
#ELSE
 MACRO RpcNsEntryObjectInqBegin = RpcNsEntryObjectInqBeginA
#ENDIF
DECLARE FUNCTION RpcNsEntryObjectInqNext LIB "rpcns4.dll" ALIAS "RpcNsEntryObjectInqNext" ( BYVAL InquiryContext AS QUAD , BYREF ObjUuid AS GUID ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsEntryObjectInqDone LIB "rpcns4.dll" ALIAS "RpcNsEntryObjectInqDone" ( BYREF InquiryContext AS QUAD ' IN OUT RPC_NS_HANDLE * InquiryContext ) AS LONG ' RPC_STATUS
'/* Management and MISC APIs */
DECLARE FUNCTION RpcNsEntryExpandNameA LIB "rpcns4.dll" ALIAS "RpcNsEntryExpandNameA" ( BYVAL EntryNameSyntax AS QUAD , BYREF EntryName AS ASCIIZ , BYREF ExpandedName AS QUAD ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsEntryExpandNameW LIB "rpcns4.dll" ALIAS "RpcNsEntryExpandNameW" ( BYVAL EntryNameSyntax AS QUAD , BYREF EntryName AS WSTRINGZ , BYREF ExpandedName AS QUAD ) AS LONG ' RPC_STATUS
#IF %DEF(%UNICODE)
 MACRO RpcNsEntryExpandName = RpcNsEntryExpandNameW
#ELSE
 MACRO RpcNsEntryExpandName = RpcNsEntryExpandNameA
#ENDIF
DECLARE FUNCTION RpcNsMgmtBindingUnexportA LIB "rpcns4.dll" ALIAS "RpcNsMgmtBindingUnexportA" ( BYVAL EntryNameSyntax AS QUAD , BYREF EntryName AS ASCIIZ , BYVAL IfId AS QUAD , BYVAL VersOption AS QUAD , BYREF ObjectUuidVec AS UUID_VECTOR ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsMgmtBindingUnexportW LIB "rpcns4.dll" ALIAS "RpcNsMgmtBindingUnexportW" ( BYVAL EntryNameSyntax AS QUAD , BYREF EntryName AS WSTRINGZ , BYVAL IfId AS QUAD , BYVAL VersOption AS QUAD , BYREF ObjectUuidVec AS UUID_VECTOR ) AS LONG ' RPC_STATUS
#IF %DEF(%UNICODE)
 MACRO RpcNsMgmtBindingUnexport = RpcNsMgmtBindingUnexportW
#ELSE
 MACRO RpcNsMgmtBindingUnexport = RpcNsMgmtBindingUnexportA
#ENDIF
DECLARE FUNCTION RpcNsMgmtEntryCreateA LIB "rpcns4.dll" ALIAS "RpcNsMgmtEntryCreateA" ( BYVAL EntryNameSyntax AS QUAD , BYREF EntryName AS ASCIIZ ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsMgmtEntryCreateW LIB "rpcns4.dll" ALIAS "RpcNsMgmtEntryCreateW" ( BYVAL EntryNameSyntax AS QUAD , BYREF EntryName AS WSTRINGZ ) AS LONG ' RPC_STATUS
#IF %DEF(%UNICODE)
 MACRO RpcNsMgmtEntryCreate = RpcNsMgmtEntryCreateW
#ELSE
 MACRO RpcNsMgmtEntryCreate = RpcNsMgmtEntryCreateA
#ENDIF
DECLARE FUNCTION RpcNsMgmtEntryDeleteA LIB "rpcns4.dll" ALIAS "RpcNsMgmtEntryDeleteA" ( BYVAL EntryNameSyntax AS QUAD , BYREF EntryName AS ASCIIZ ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsMgmtEntryDeleteW LIB "rpcns4.dll" ALIAS "RpcNsMgmtEntryDeleteW" ( BYVAL EntryNameSyntax AS QUAD , BYREF EntryName AS WSTRINGZ ) AS LONG ' RPC_STATUS
#IF %DEF(%UNICODE)
 MACRO RpcNsMgmtEntryDelete = RpcNsMgmtEntryDeleteW
#ELSE
 MACRO RpcNsMgmtEntryDelete = RpcNsMgmtEntryDeleteA
#ENDIF
DECLARE FUNCTION RpcNsMgmtEntryInqIfIdsA LIB "rpcns4.dll" ALIAS "RpcNsMgmtEntryInqIfIdsA" ( BYVAL EntryNameSyntax AS QUAD , BYREF EntryName AS ASCIIZ , BYREF IfIdVec AS RPC_IF_ID_VECTOR ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsMgmtEntryInqIfIdsW LIB "rpcns4.dll" ALIAS "RpcNsMgmtEntryInqIfIdsW" ( BYVAL EntryNameSyntax AS QUAD , BYREF EntryName AS WSTRINGZ , BYREF IfIdVec AS RPC_IF_ID_VECTOR ) AS LONG ' RPC_STATUS
#IF %DEF(%UNICODE)
 MACRO RpcNsMgmtEntryInqIfIds = RpcNsMgmtEntryInqIfIdsW
#ELSE
 MACRO RpcNsMgmtEntryInqIfIds = RpcNsMgmtEntryInqIfIdsA
#ENDIF
DECLARE FUNCTION RpcNsMgmtHandleSetExpAge LIB "rpcns4.dll" ALIAS "RpcNsMgmtHandleSetExpAge" ( BYVAL NsHandle AS QUAD , BYVAL ExpirationAge AS QUAD ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsMgmtInqExpAge LIB "rpcns4.dll" ALIAS "RpcNsMgmtInqExpAge" ( BYREF ExpirationAge AS QUAD ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsMgmtSetExpAge LIB "rpcns4.dll" ALIAS "RpcNsMgmtSetExpAge" ( BYVAL ExpirationAge AS QUAD ) AS LONG ' RPC_STATUS
'/* Client API's implemented in wrappers. */
DECLARE FUNCTION RpcNsBindingImportBeginA LIB "rpcns4.dll" ALIAS "RpcNsBindingImportBeginA" ( BYVAL EntryNameSyntax AS QUAD , BYREF EntryName AS ASCIIZ , BYVAL IfSpec AS QUAD , BYREF ObjUuid AS GUID , BYREF ImportContext AS QUAD ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsBindingImportBeginW LIB "rpcns4.dll" ALIAS "RpcNsBindingImportBeginW" ( BYVAL EntryNameSyntax AS QUAD , BYVAL EntryName AS QUAD , BYVAL IfSpec AS QUAD , BYREF ObjUuid AS GUID , BYREF ImportContext AS QUAD ) AS LONG ' RPC_STATUS
#IF %DEF(%UNICODE)
 MACRO RpcNsBindingImportBegin = RpcNsBindingImportBeginW
#ELSE
 MACRO RpcNsBindingImportBegin = RpcNsBindingImportBeginA
#ENDIF
DECLARE FUNCTION RpcNsBindingImportNext LIB "rpcns4.dll" ALIAS "RpcNsBindingImportNext" ( BYVAL ImportContext AS QUAD , BYREF Binding AS QUAD ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsBindingImportDone LIB "rpcns4.dll" ALIAS "RpcNsBindingImportDone" ( BYVAL ImportContext AS QUAD ) AS LONG ' RPC_STATUS
DECLARE FUNCTION RpcNsBindingSelect LIB "rpcns4.dll" ALIAS "RpcNsBindingSelect" ( BYREF BindingVec AS RPC_BINDING_VECTOR , BYREF Binding AS QUAD ) AS LONG ' RPC_STATUS
#ENDIF
