VirtualBox

source: vbox/trunk/src/VBox/Additions/WINNT/Graphics/Wine/include/rpcndr.h@ 19678

Last change on this file since 19678 was 19678, checked in by vboxsync, 16 years ago

opengl: update wine to 1.1.21, add d3d9.dll to build list

  • Property svn:eol-style set to native
File size: 25.5 KB
Line 
1/*
2 * Copyright (C) 2000 Francois Gouget
3 *
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
8 *
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
13 *
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
17 */
18
19/*
20 * Sun LGPL Disclaimer: For the avoidance of doubt, except that if any license choice
21 * other than GPL or LGPL is available it will apply instead, Sun elects to use only
22 * the Lesser General Public License version 2.1 (LGPLv2) at this time for any software where
23 * a choice of LGPL license versions is made available with the language indicating
24 * that LGPLv2 or any later version may be used, or where a choice of which version
25 * of the LGPL is applied is otherwise unspecified.
26 */
27
28#ifndef __RPCNDR_H_VERSION__
29/* FIXME: What version? Perhaps something is better than nothing, however incorrect */
30#define __RPCNDR_H_VERSION__ ( 399 )
31#endif
32
33#ifndef __WINE_RPCNDR_H
34#define __WINE_RPCNDR_H
35
36#ifdef __cplusplus
37extern "C" {
38#endif
39
40#include <basetsd.h>
41
42#undef CONST_VTBL
43#ifdef CONST_VTABLE
44# define CONST_VTBL const
45#else
46# define CONST_VTBL
47#endif
48
49/* stupid #if can't handle casts... this __stupidity
50 is just a workaround for that limitation */
51
52#define __NDR_CHAR_REP_MASK 0x000fL
53#define __NDR_INT_REP_MASK 0x00f0L
54#define __NDR_FLOAT_REP_MASK 0xff00L
55
56#define __NDR_IEEE_FLOAT 0x0000L
57#define __NDR_VAX_FLOAT 0x0100L
58#define __NDR_IBM_FLOAT 0x0300L
59
60#define __NDR_ASCII_CHAR 0x0000L
61#define __NDR_EBCDIC_CHAR 0x0001L
62
63#define __NDR_LITTLE_ENDIAN 0x0010L
64#define __NDR_BIG_ENDIAN 0x0000L
65
66/* Mac's are special */
67#if defined(__RPC_MAC__)
68# define __NDR_LOCAL_DATA_REPRESENTATION \
69 (__NDR_IEEE_FLOAT | __NDR_ASCII_CHAR | __NDR_BIG_ENDIAN)
70#else
71# define __NDR_LOCAL_DATA_REPRESENTATION \
72 (__NDR_IEEE_FLOAT | __NDR_ASCII_CHAR | __NDR_LITTLE_ENDIAN)
73#endif
74
75#define __NDR_LOCAL_ENDIAN \
76 (__NDR_LOCAL_DATA_REPRESENTATION & __NDR_INT_REP_MASK)
77
78/* for convenience, define NDR_LOCAL_IS_BIG_ENDIAN iff it is */
79#if __NDR_LOCAL_ENDIAN == __NDR_BIG_ENDIAN
80# define NDR_LOCAL_IS_BIG_ENDIAN
81#elif __NDR_LOCAL_ENDIAN == __NDR_LITTLE_ENDIAN
82# undef NDR_LOCAL_IS_BIG_ENDIAN
83#else
84# error alien NDR_LOCAL_ENDIAN - Greg botched the defines again, please report
85#endif
86
87/* finally, do the casts like Microsoft */
88
89#define NDR_CHAR_REP_MASK ((ULONG) __NDR_CHAR_REP_MASK)
90#define NDR_INT_REP_MASK ((ULONG) __NDR_INT_REP_MASK)
91#define NDR_FLOAT_REP_MASK ((ULONG) __NDR_FLOAT_REP_MASK)
92#define NDR_IEEE_FLOAT ((ULONG) __NDR_IEEE_FLOAT)
93#define NDR_VAX_FLOAT ((ULONG) __NDR_VAX_FLOAT)
94#define NDR_IBM_FLOAT ((ULONG) __NDR_IBM_FLOAT)
95#define NDR_ASCII_CHAR ((ULONG) __NDR_ASCII_CHAR)
96#define NDR_EBCDIC_CHAR ((ULONG) __NDR_EBCDIC_CHAR)
97#define NDR_LITTLE_ENDIAN ((ULONG) __NDR_LITTLE_ENDIAN)
98#define NDR_BIG_ENDIAN ((ULONG) __NDR_BIG_ENDIAN)
99#define NDR_LOCAL_DATA_REPRESENTATION ((ULONG) __NDR_LOCAL_DATA_REPRESENTATION)
100#define NDR_LOCAL_ENDIAN ((ULONG) __NDR_LOCAL_ENDIAN)
101
102
103#define TARGET_IS_NT50_OR_LATER 1
104#define TARGET_IS_NT40_OR_LATER 1
105#define TARGET_IS_NT351_OR_WIN95_OR_LATER 1
106
107#define small char
108typedef unsigned char byte;
109#define hyper __int64
110#define MIDL_uhyper unsigned __int64
111typedef unsigned char boolean;
112
113#define __RPC_CALLEE WINAPI
114#define RPC_VAR_ENTRY __cdecl
115#define NDR_SHAREABLE static
116
117#define MIDL_ascii_strlen(s) strlen(s)
118#define MIDL_ascii_strcpy(d,s) strcpy(d,s)
119#define MIDL_memset(d,v,n) memset(d,v,n)
120#define midl_user_free MIDL_user_free
121#define midl_user_allocate MIDL_user_allocate
122
123#define NdrFcShort(s) (unsigned char)(s & 0xff), (unsigned char)(s >> 8)
124#define NdrFcLong(s) (unsigned char)(s & 0xff), (unsigned char)((s & 0x0000ff00) >> 8), \
125 (unsigned char)((s & 0x00ff0000) >> 16), (unsigned char)(s >> 24)
126
127#define RPC_BAD_STUB_DATA_EXCEPTION_FILTER \
128 ((RpcExceptionCode() == STATUS_ACCESS_VIOLATION) || \
129 (RpcExceptionCode() == STATUS_DATATYPE_MISALIGNMENT) || \
130 (RpcExceptionCode() == RPC_X_BAD_STUB_DATA) || \
131 (RpcExceptionCode() == RPC_S_INVALID_BOUND))
132
133typedef struct
134{
135 void *pad[2];
136 void *userContext;
137} *NDR_SCONTEXT;
138
139#define NDRSContextValue(hContext) (&(hContext)->userContext)
140#define cbNDRContext 20
141
142typedef void (__RPC_USER *NDR_RUNDOWN)(void *context);
143typedef void (__RPC_USER *NDR_NOTIFY_ROUTINE)(void);
144typedef void (__RPC_USER *NDR_NOTIFY2_ROUTINE)(boolean flag);
145
146#define DECLSPEC_UUID(x)
147#define MIDL_INTERFACE(x) struct
148
149struct _MIDL_STUB_MESSAGE;
150struct _MIDL_STUB_DESC;
151struct _FULL_PTR_XLAT_TABLES;
152struct NDR_ALLOC_ALL_NODES_CONTEXT;
153struct NDR_POINTER_QUEUE_STATE;
154
155typedef unsigned char *RPC_BUFPTR;
156typedef ULONG RPC_LENGTH;
157typedef void (__RPC_USER *EXPR_EVAL)(struct _MIDL_STUB_MESSAGE *);
158typedef const unsigned char *PFORMAT_STRING;
159
160typedef struct
161{
162 LONG Dimension;
163 ULONG *BufferConformanceMark;
164 ULONG *BufferVarianceMark;
165 ULONG *MaxCountArray;
166 ULONG *OffsetArray;
167 ULONG *ActualCountArray;
168} ARRAY_INFO, *PARRAY_INFO;
169
170typedef struct
171{
172 ULONG WireCodeset;
173 ULONG DesiredReceivingCodeset;
174 void *CSArrayInfo;
175} CS_STUB_INFO;
176
177typedef struct _NDR_PIPE_DESC *PNDR_PIPE_DESC;
178typedef struct _NDR_PIPE_MESSAGE *PNDR_PIPE_MESSAGE;
179typedef struct _NDR_ASYNC_MESSAGE *PNDR_ASYNC_MESSAGE;
180typedef struct _NDR_CORRELATION_INFO *PNDR_CORRELATION_INFO;
181
182#include <pshpack4.h>
183typedef struct _MIDL_STUB_MESSAGE
184{
185 PRPC_MESSAGE RpcMsg;
186 unsigned char *Buffer;
187 unsigned char *BufferStart;
188 unsigned char *BufferEnd;
189 unsigned char *BufferMark;
190 ULONG BufferLength;
191 ULONG MemorySize;
192 unsigned char *Memory;
193 unsigned char IsClient;
194 unsigned char Pad;
195 unsigned short uFlags2;
196 int ReuseBuffer;
197 struct NDR_ALLOC_ALL_NODES_CONTEXT *pAllocAllNodesContext;
198 struct NDR_POINTER_QUEUE_STATE *pPointerQueueState;
199 int IgnoreEmbeddedPointers;
200 unsigned char *PointerBufferMark;
201 unsigned char CorrDespIncrement;
202 unsigned char uFlags;
203 unsigned short UniquePtrCount;
204 ULONG_PTR MaxCount;
205 ULONG Offset;
206 ULONG ActualCount;
207 void * (__WINE_ALLOC_SIZE(1) __RPC_API *pfnAllocate)(SIZE_T);
208 void (__RPC_API *pfnFree)(void *);
209 unsigned char *StackTop;
210 unsigned char *pPresentedType;
211 unsigned char *pTransmitType;
212 handle_t SavedHandle;
213 const struct _MIDL_STUB_DESC *StubDesc;
214 struct _FULL_PTR_XLAT_TABLES *FullPtrXlatTables;
215 ULONG FullPtrRefId;
216 ULONG PointerLength;
217 int fInDontFree:1;
218 int fDontCallFreeInst:1;
219 int fInOnlyParam:1;
220 int fHasReturn:1;
221 int fHasExtensions:1;
222 int fHasNewCorrDesc:1;
223 int fIsIn:1;
224 int fIsOut:1;
225 int fIsOicf:1;
226 int fBufferValid:1;
227 int fHasMemoryValidateCallback:1;
228 int fInFree:1;
229 int fNeedMCCP:1;
230 int fUnused:3;
231 int fUnused2:16;
232 DWORD dwDestContext;
233 void *pvDestContext;
234 NDR_SCONTEXT *SavedContextHandles;
235 LONG ParamNumber;
236 struct IRpcChannelBuffer *pRpcChannelBuffer;
237 PARRAY_INFO pArrayInfo;
238 ULONG *SizePtrCountArray;
239 ULONG *SizePtrOffsetArray;
240 ULONG *SizePtrLengthArray;
241 void *pArgQueue;
242 DWORD dwStubPhase;
243 void *LowStackMark;
244 PNDR_ASYNC_MESSAGE pAsyncMsg;
245 PNDR_CORRELATION_INFO pCorrInfo;
246 unsigned char *pCorrMemory;
247 void *pMemoryList;
248 CS_STUB_INFO *pCSInfo;
249 unsigned char *ConformanceMark;
250 unsigned char *VarianceMark;
251 INT_PTR Unused; /* BackingStoreLowMark on IA64 */
252 struct _NDR_PROC_CONTEXT *pContext;
253 void* ContextHandleHash;
254 void* pUserMarshalList;
255 INT_PTR Reserved51_3;
256 INT_PTR Reserved51_4;
257 INT_PTR Reserved51_5;
258} MIDL_STUB_MESSAGE, *PMIDL_STUB_MESSAGE;
259#include <poppack.h>
260
261typedef void * (__RPC_API * GENERIC_BINDING_ROUTINE)(void *);
262typedef void (__RPC_API * GENERIC_UNBIND_ROUTINE)(void *, unsigned char *);
263
264typedef struct _GENERIC_BINDING_ROUTINE_PAIR
265{
266 GENERIC_BINDING_ROUTINE pfnBind;
267 GENERIC_UNBIND_ROUTINE pfnUnbind;
268} GENERIC_BINDING_ROUTINE_PAIR, *PGENERIC_BINDING_ROUTINE_PAIR;
269
270typedef struct __GENERIC_BINDING_INFO
271{
272 void *pObj;
273 unsigned int Size;
274 GENERIC_BINDING_ROUTINE pfnBind;
275 GENERIC_UNBIND_ROUTINE pfnUnbind;
276} GENERIC_BINDING_INFO, *PGENERIC_BINDING_INFO;
277
278typedef void (__RPC_USER *XMIT_HELPER_ROUTINE)(PMIDL_STUB_MESSAGE);
279
280typedef struct _XMIT_ROUTINE_QUINTUPLE
281{
282 XMIT_HELPER_ROUTINE pfnTranslateToXmit;
283 XMIT_HELPER_ROUTINE pfnTranslateFromXmit;
284 XMIT_HELPER_ROUTINE pfnFreeXmit;
285 XMIT_HELPER_ROUTINE pfnFreeInst;
286} XMIT_ROUTINE_QUINTUPLE, *PXMIT_ROUTINE_QUINTUPLE;
287
288typedef ULONG (__RPC_USER *USER_MARSHAL_SIZING_ROUTINE)(ULONG *, ULONG, void *);
289typedef unsigned char * (__RPC_USER *USER_MARSHAL_MARSHALLING_ROUTINE)(ULONG *, unsigned char *, void *);
290typedef unsigned char * (__RPC_USER *USER_MARSHAL_UNMARSHALLING_ROUTINE)(ULONG *, unsigned char *, void *);
291typedef void (__RPC_USER *USER_MARSHAL_FREEING_ROUTINE)(ULONG *, void *);
292
293typedef struct _USER_MARSHAL_ROUTINE_QUADRUPLE
294{
295 USER_MARSHAL_SIZING_ROUTINE pfnBufferSize;
296 USER_MARSHAL_MARSHALLING_ROUTINE pfnMarshall;
297 USER_MARSHAL_UNMARSHALLING_ROUTINE pfnUnmarshall;
298 USER_MARSHAL_FREEING_ROUTINE pfnFree;
299} USER_MARSHAL_ROUTINE_QUADRUPLE;
300
301/* 'USRC' */
302#define USER_MARSHAL_CB_SIGNATURE \
303 ( ( (DWORD)'U' << 24 ) | ( (DWORD)'S' << 16 ) | \
304 ( (DWORD)'R' << 8 ) | ( (DWORD)'C' ) )
305
306typedef enum
307{
308 USER_MARSHAL_CB_BUFFER_SIZE,
309 USER_MARSHAL_CB_MARSHALL,
310 USER_MARSHAL_CB_UNMARSHALL,
311 USER_MARSHAL_CB_FREE
312} USER_MARSHAL_CB_TYPE;
313
314typedef struct _USER_MARSHAL_CB
315{
316 ULONG Flags;
317 PMIDL_STUB_MESSAGE pStubMsg;
318 PFORMAT_STRING pReserve;
319 ULONG Signature;
320 USER_MARSHAL_CB_TYPE CBType;
321 PFORMAT_STRING pFormat;
322 PFORMAT_STRING pTypeFormat;
323} USER_MARSHAL_CB;
324
325#define USER_CALL_CTXT_MASK(f) ((f) & 0x00ff)
326#define USER_CALL_AUX_MASK(f) ((f) & 0xff00)
327#define GET_USER_DATA_REP(f) HIWORD(f)
328
329#define USER_CALL_IS_ASYNC 0x0100
330#define USER_CALL_NEW_CORRELATION_DESC 0x0200
331
332typedef struct _MALLOC_FREE_STRUCT
333{
334 void * (__WINE_ALLOC_SIZE(1) __RPC_USER *pfnAllocate)(SIZE_T);
335 void (__RPC_USER *pfnFree)(void *);
336} MALLOC_FREE_STRUCT;
337
338typedef struct _COMM_FAULT_OFFSETS
339{
340 short CommOffset;
341 short FaultOffset;
342} COMM_FAULT_OFFSETS;
343
344typedef struct _MIDL_STUB_DESC
345{
346 void *RpcInterfaceInformation;
347 void * (__WINE_ALLOC_SIZE(1) __RPC_API *pfnAllocate)(SIZE_T);
348 void (__RPC_API *pfnFree)(void *);
349 union {
350 handle_t *pAutoHandle;
351 handle_t *pPrimitiveHandle;
352 PGENERIC_BINDING_INFO pGenericBindingInfo;
353 } IMPLICIT_HANDLE_INFO;
354 const NDR_RUNDOWN *apfnNdrRundownRoutines;
355 const GENERIC_BINDING_ROUTINE_PAIR *aGenericBindingRoutinePairs;
356 const EXPR_EVAL *apfnExprEval;
357 const XMIT_ROUTINE_QUINTUPLE *aXmitQuintuple;
358 const unsigned char *pFormatTypes;
359 int fCheckBounds;
360 ULONG Version;
361 MALLOC_FREE_STRUCT *pMallocFreeStruct;
362 LONG MIDLVersion;
363 const COMM_FAULT_OFFSETS *CommFaultOffsets;
364 const USER_MARSHAL_ROUTINE_QUADRUPLE *aUserMarshalQuadruple;
365 const NDR_NOTIFY_ROUTINE *NotifyRoutineTable;
366 ULONG_PTR mFlags;
367 ULONG_PTR Reserved3;
368 ULONG_PTR Reserved4;
369 ULONG_PTR Reserved5;
370} MIDL_STUB_DESC;
371typedef const MIDL_STUB_DESC *PMIDL_STUB_DESC;
372
373typedef struct _MIDL_FORMAT_STRING
374{
375 short Pad;
376#if defined(__GNUC__)
377 unsigned char Format[0];
378#else
379 unsigned char Format[1];
380#endif
381} MIDL_FORMAT_STRING;
382
383typedef struct _MIDL_SYNTAX_INFO
384{
385 RPC_SYNTAX_IDENTIFIER TransferSyntax;
386 RPC_DISPATCH_TABLE* DispatchTable;
387 PFORMAT_STRING ProcString;
388 const unsigned short* FmtStringOffset;
389 PFORMAT_STRING TypeString;
390 const void* aUserMarshalQuadruple;
391 ULONG_PTR pReserved1;
392 ULONG_PTR pReserved2;
393} MIDL_SYNTAX_INFO, *PMIDL_SYNTAX_INFO;
394
395typedef void (__RPC_API *STUB_THUNK)( PMIDL_STUB_MESSAGE );
396
397typedef LONG (__RPC_API *SERVER_ROUTINE)();
398
399typedef struct _MIDL_SERVER_INFO_
400{
401 PMIDL_STUB_DESC pStubDesc;
402 const SERVER_ROUTINE *DispatchTable;
403 PFORMAT_STRING ProcString;
404 const unsigned short *FmtStringOffset;
405 const STUB_THUNK *ThunkTable;
406 PRPC_SYNTAX_IDENTIFIER pTransferSyntax;
407 ULONG_PTR nCount;
408 PMIDL_SYNTAX_INFO pSyntaxInfo;
409} MIDL_SERVER_INFO, *PMIDL_SERVER_INFO;
410
411typedef struct _MIDL_STUBLESS_PROXY_INFO
412{
413 PMIDL_STUB_DESC pStubDesc;
414 PFORMAT_STRING ProcFormatString;
415 const unsigned short *FormatStringOffset;
416 PRPC_SYNTAX_IDENTIFIER pTransferSyntax;
417 ULONG_PTR nCount;
418 PMIDL_SYNTAX_INFO pSyntaxInfo;
419} MIDL_STUBLESS_PROXY_INFO, *PMIDL_STUBLESS_PROXY_INFO;
420
421typedef union _CLIENT_CALL_RETURN
422{
423 void *Pointer;
424 LONG_PTR Simple;
425} CLIENT_CALL_RETURN;
426
427typedef enum {
428 STUB_UNMARSHAL,
429 STUB_CALL_SERVER,
430 STUB_MARSHAL,
431 STUB_CALL_SERVER_NO_HRESULT
432} STUB_PHASE;
433
434typedef enum {
435 PROXY_CALCSIZE,
436 PROXY_GETBUFFER,
437 PROXY_MARSHAL,
438 PROXY_SENDRECEIVE,
439 PROXY_UNMARSHAL
440} PROXY_PHASE;
441
442typedef enum {
443 XLAT_SERVER = 1,
444 XLAT_CLIENT
445} XLAT_SIDE;
446
447typedef struct _FULL_PTR_TO_REFID_ELEMENT {
448 struct _FULL_PTR_TO_REFID_ELEMENT *Next;
449 void *Pointer;
450 ULONG RefId;
451 unsigned char State;
452} FULL_PTR_TO_REFID_ELEMENT, *PFULL_PTR_TO_REFID_ELEMENT;
453
454/* Full pointer translation tables */
455typedef struct _FULL_PTR_XLAT_TABLES {
456 struct {
457 void **XlatTable;
458 unsigned char *StateTable;
459 ULONG NumberOfEntries;
460 } RefIdToPointer;
461
462 struct {
463 PFULL_PTR_TO_REFID_ELEMENT *XlatTable;
464 ULONG NumberOfBuckets;
465 ULONG HashMask;
466 } PointerToRefId;
467
468 ULONG NextRefId;
469 XLAT_SIDE XlatSide;
470} FULL_PTR_XLAT_TABLES, *PFULL_PTR_XLAT_TABLES;
471
472struct IRpcStubBuffer;
473
474typedef ULONG error_status_t;
475typedef void * NDR_CCONTEXT;
476
477typedef struct _SCONTEXT_QUEUE {
478 ULONG NumberOfObjects;
479 NDR_SCONTEXT *ArrayOfObjects;
480} SCONTEXT_QUEUE, *PSCONTEXT_QUEUE;
481
482typedef struct _NDR_USER_MARSHAL_INFO_LEVEL1
483{
484 void *Buffer;
485 ULONG BufferSize;
486 void * (__WINE_ALLOC_SIZE(1) __RPC_API *pfnAllocate)(SIZE_T);
487 void (__RPC_API *pfnFree)(void *);
488 struct IRpcChannelBuffer *pRpcChannelBuffer;
489 ULONG_PTR Reserved[5];
490} NDR_USER_MARSHAL_INFO_LEVEL1;
491
492typedef struct _NDR_USER_MARSHAL_INFO
493{
494 ULONG InformationLevel;
495 union
496 {
497 NDR_USER_MARSHAL_INFO_LEVEL1 Level1;
498 } DUMMYUNIONNAME1;
499} NDR_USER_MARSHAL_INFO;
500
501/* Context Handles */
502
503RPCRTAPI RPC_BINDING_HANDLE RPC_ENTRY
504 NDRCContextBinding( NDR_CCONTEXT CContext );
505
506RPCRTAPI void RPC_ENTRY
507 NDRCContextMarshall( NDR_CCONTEXT CContext, void *pBuff );
508
509RPCRTAPI void RPC_ENTRY
510 NDRCContextUnmarshall( NDR_CCONTEXT *pCContext, RPC_BINDING_HANDLE hBinding,
511 void *pBuff, ULONG DataRepresentation );
512
513RPCRTAPI void RPC_ENTRY
514 NDRSContextMarshall( NDR_SCONTEXT CContext, void *pBuff, NDR_RUNDOWN userRunDownIn );
515
516RPCRTAPI NDR_SCONTEXT RPC_ENTRY
517 NDRSContextUnmarshall( void *pBuff, ULONG DataRepresentation );
518
519RPCRTAPI void RPC_ENTRY
520 NDRSContextMarshallEx( RPC_BINDING_HANDLE BindingHandle, NDR_SCONTEXT CContext,
521 void *pBuff, NDR_RUNDOWN userRunDownIn );
522
523RPCRTAPI void RPC_ENTRY
524 NDRSContextMarshall2( RPC_BINDING_HANDLE BindingHandle, NDR_SCONTEXT CContext,
525 void *pBuff, NDR_RUNDOWN userRunDownIn, void * CtxGuard,
526 ULONG Flags );
527
528RPCRTAPI NDR_SCONTEXT RPC_ENTRY
529 NDRSContextUnmarshallEx( RPC_BINDING_HANDLE BindingHandle, void *pBuff,
530 ULONG DataRepresentation );
531
532RPCRTAPI NDR_SCONTEXT RPC_ENTRY
533 NDRSContextUnmarshall2( RPC_BINDING_HANDLE BindingHandle, void *pBuff,
534 ULONG DataRepresentation, void *CtxGuard,
535 ULONG Flags );
536
537RPCRTAPI void RPC_ENTRY
538 NdrClientContextMarshall ( PMIDL_STUB_MESSAGE pStubMsg, NDR_CCONTEXT ContextHandle, int fCheck );
539
540RPCRTAPI void RPC_ENTRY
541 NdrClientContextUnmarshall( PMIDL_STUB_MESSAGE pStubMsg, NDR_CCONTEXT* pContextHandle,
542 RPC_BINDING_HANDLE BindHandle );
543
544RPCRTAPI void RPC_ENTRY
545 NdrServerContextMarshall ( PMIDL_STUB_MESSAGE pStubMsg, NDR_SCONTEXT ContextHandle, NDR_RUNDOWN RundownRoutine );
546
547RPCRTAPI NDR_SCONTEXT RPC_ENTRY
548 NdrServerContextUnmarshall( PMIDL_STUB_MESSAGE pStubMsg );
549
550RPCRTAPI void RPC_ENTRY
551 NdrContextHandleSize( PMIDL_STUB_MESSAGE pStubMsg, unsigned char* pMemory, PFORMAT_STRING pFormat );
552
553RPCRTAPI NDR_SCONTEXT RPC_ENTRY
554 NdrContextHandleInitialize( PMIDL_STUB_MESSAGE pStubMsg, PFORMAT_STRING pFormat );
555
556RPCRTAPI void RPC_ENTRY
557 NdrServerContextNewMarshall( PMIDL_STUB_MESSAGE pStubMsg, NDR_SCONTEXT ContextHandle,
558 NDR_RUNDOWN RundownRoutine, PFORMAT_STRING pFormat );
559
560RPCRTAPI NDR_SCONTEXT RPC_ENTRY
561 NdrServerContextNewUnmarshall( PMIDL_STUB_MESSAGE pStubMsg, PFORMAT_STRING pFormat );
562
563RPCRTAPI RPC_STATUS RPC_ENTRY
564 RpcSmDestroyClientContext( void **ContextHandle );
565
566RPCRTAPI void RPC_ENTRY
567 RpcSsDestroyClientContext( void **ContextHandle );
568
569RPCRTAPI void RPC_ENTRY
570 NdrSimpleTypeMarshall( PMIDL_STUB_MESSAGE pStubMsg, unsigned char* pMemory, unsigned char FormatChar );
571RPCRTAPI void RPC_ENTRY
572 NdrSimpleTypeUnmarshall( PMIDL_STUB_MESSAGE pStubMsg, unsigned char* pMemory, unsigned char FormatChar );
573
574RPCRTAPI unsigned char* RPC_ENTRY
575 NdrByteCountPointerMarshall( PMIDL_STUB_MESSAGE pStubMsg, unsigned char* pMemory, PFORMAT_STRING pFormat );
576RPCRTAPI unsigned char* RPC_ENTRY
577 NdrByteCountPointerUnmarshall( PMIDL_STUB_MESSAGE pStubMsg, unsigned char** ppMemory, PFORMAT_STRING pFormat, unsigned char fMustAlloc );
578RPCRTAPI void RPC_ENTRY
579 NdrByteCountPointerBufferSize( PMIDL_STUB_MESSAGE pStubMsg, unsigned char* pMemory, PFORMAT_STRING pFormat );
580RPCRTAPI void RPC_ENTRY
581 NdrByteCountPointerFree( PMIDL_STUB_MESSAGE pStubMsg, unsigned char* pMemory, PFORMAT_STRING pFormat );
582
583RPCRTAPI unsigned char* RPC_ENTRY
584 NdrRangeUnmarshall( PMIDL_STUB_MESSAGE pStubMsg, unsigned char** ppMemory, PFORMAT_STRING pFormat, unsigned char fMustAlloc );
585
586/* while MS declares each prototype separately, I prefer to use macros for this kind of thing instead */
587#define SIMPLE_TYPE_MARSHAL(type) \
588RPCRTAPI unsigned char* RPC_ENTRY \
589 Ndr##type##Marshall( PMIDL_STUB_MESSAGE pStubMsg, unsigned char* pMemory, PFORMAT_STRING pFormat ); \
590RPCRTAPI unsigned char* RPC_ENTRY \
591 Ndr##type##Unmarshall( PMIDL_STUB_MESSAGE pStubMsg, unsigned char** ppMemory, PFORMAT_STRING pFormat, unsigned char fMustAlloc ); \
592RPCRTAPI void RPC_ENTRY \
593 Ndr##type##BufferSize( PMIDL_STUB_MESSAGE pStubMsg, unsigned char* pMemory, PFORMAT_STRING pFormat ); \
594RPCRTAPI ULONG RPC_ENTRY \
595 Ndr##type##MemorySize( PMIDL_STUB_MESSAGE pStubMsg, PFORMAT_STRING pFormat );
596
597#define TYPE_MARSHAL(type) \
598 SIMPLE_TYPE_MARSHAL(type) \
599RPCRTAPI void RPC_ENTRY \
600 Ndr##type##Free( PMIDL_STUB_MESSAGE pStubMsg, unsigned char* pMemory, PFORMAT_STRING pFormat );
601
602TYPE_MARSHAL(Pointer)
603TYPE_MARSHAL(SimpleStruct)
604TYPE_MARSHAL(ConformantStruct)
605TYPE_MARSHAL(ConformantVaryingStruct)
606TYPE_MARSHAL(ComplexStruct)
607TYPE_MARSHAL(FixedArray)
608TYPE_MARSHAL(ConformantArray)
609TYPE_MARSHAL(ConformantVaryingArray)
610TYPE_MARSHAL(VaryingArray)
611TYPE_MARSHAL(ComplexArray)
612TYPE_MARSHAL(EncapsulatedUnion)
613TYPE_MARSHAL(NonEncapsulatedUnion)
614TYPE_MARSHAL(XmitOrRepAs)
615TYPE_MARSHAL(UserMarshal)
616TYPE_MARSHAL(InterfacePointer)
617
618SIMPLE_TYPE_MARSHAL(ConformantString)
619SIMPLE_TYPE_MARSHAL(NonConformantString)
620
621#undef TYPE_MARSHAL
622#undef SIMPLE_TYPE_MARSHAL
623
624RPCRTAPI void RPC_ENTRY
625 NdrCorrelationInitialize( PMIDL_STUB_MESSAGE pStubMsg, void *pMemory, ULONG CacheSize, ULONG flags );
626RPCRTAPI void RPC_ENTRY
627 NdrCorrelationPass( PMIDL_STUB_MESSAGE pStubMsg );
628RPCRTAPI void RPC_ENTRY
629 NdrCorrelationFree( PMIDL_STUB_MESSAGE pStubMsg );
630
631RPCRTAPI void RPC_ENTRY
632 NdrConvert2( PMIDL_STUB_MESSAGE pStubMsg, PFORMAT_STRING pFormat, LONG NumberParams );
633RPCRTAPI void RPC_ENTRY
634 NdrConvert( PMIDL_STUB_MESSAGE pStubMsg, PFORMAT_STRING pFormat );
635
636#define USER_MARSHAL_FC_BYTE 1
637#define USER_MARSHAL_FC_CHAR 2
638#define USER_MARSHAL_FC_SMALL 3
639#define USER_MARSHAL_FC_USMALL 4
640#define USER_MARSHAL_FC_WCHAR 5
641#define USER_MARSHAL_FC_SHORT 6
642#define USER_MARSHAL_FC_USHORT 7
643#define USER_MARSHAL_FC_LONG 8
644#define USER_MARSHAL_FC_ULONG 9
645#define USER_MARSHAL_FC_FLOAT 10
646#define USER_MARSHAL_FC_HYPER 11
647#define USER_MARSHAL_FC_DOUBLE 12
648
649RPCRTAPI unsigned char* RPC_ENTRY
650 NdrUserMarshalSimpleTypeConvert( ULONG *pFlags, unsigned char *pBuffer, unsigned char FormatChar );
651
652/* Note: this should return a CLIENT_CALL_RETURN, but calling convention for
653 * returning structures/unions is different between Windows and gcc on i386. */
654LONG_PTR RPC_VAR_ENTRY
655 NdrClientCall2( PMIDL_STUB_DESC pStubDescriptor, PFORMAT_STRING pFormat, ... );
656LONG_PTR RPC_VAR_ENTRY
657 NdrClientCall( PMIDL_STUB_DESC pStubDescriptor, PFORMAT_STRING pFormat, ... );
658LONG_PTR RPC_VAR_ENTRY
659 NdrAsyncClientCall( PMIDL_STUB_DESC pStubDescriptor, PFORMAT_STRING pFormat, ... );
660LONG_PTR RPC_VAR_ENTRY
661 NdrDcomAsyncClientCall( PMIDL_STUB_DESC pStubDescriptor, PFORMAT_STRING pFormat, ... );
662
663RPCRTAPI void RPC_ENTRY
664 NdrServerCall2( PRPC_MESSAGE pRpcMsg );
665RPCRTAPI void RPC_ENTRY
666 NdrServerCall( PRPC_MESSAGE pRpcMsg );
667RPCRTAPI void RPC_ENTRY
668 NdrAsyncServerCall( PRPC_MESSAGE pRpcMsg );
669
670RPCRTAPI LONG RPC_ENTRY
671 NdrStubCall2( struct IRpcStubBuffer* pThis, struct IRpcChannelBuffer* pChannel, PRPC_MESSAGE pRpcMsg, DWORD * pdwStubPhase );
672RPCRTAPI LONG RPC_ENTRY
673 NdrStubCall( struct IRpcStubBuffer* pThis, struct IRpcChannelBuffer* pChannel, PRPC_MESSAGE pRpcMsg, DWORD * pdwStubPhase );
674RPCRTAPI LONG RPC_ENTRY
675 NdrAsyncStubCall( struct IRpcStubBuffer* pThis, struct IRpcChannelBuffer* pChannel, PRPC_MESSAGE pRpcMsg, DWORD * pdwStubPhase );
676RPCRTAPI LONG RPC_ENTRY
677 NdrDcomAsyncStubCall( struct IRpcStubBuffer* pThis, struct IRpcChannelBuffer* pChannel, PRPC_MESSAGE pRpcMsg, DWORD * pdwStubPhase );
678
679RPCRTAPI void* RPC_ENTRY
680 NdrAllocate( PMIDL_STUB_MESSAGE pStubMsg, SIZE_T Len ) __WINE_ALLOC_SIZE(2);
681
682RPCRTAPI void RPC_ENTRY
683 NdrClearOutParameters( PMIDL_STUB_MESSAGE pStubMsg, PFORMAT_STRING pFormat, void *ArgAddr );
684
685RPCRTAPI RPC_STATUS RPC_ENTRY
686 NdrMapCommAndFaultStatus( PMIDL_STUB_MESSAGE pStubMsg, ULONG *pCommStatus,
687 ULONG *pFaultStatus, RPC_STATUS Status_ );
688
689RPCRTAPI void* RPC_ENTRY
690 NdrOleAllocate( SIZE_T Size ) __WINE_ALLOC_SIZE(1);
691RPCRTAPI void RPC_ENTRY
692 NdrOleFree( void* NodeToFree );
693
694RPCRTAPI void RPC_ENTRY
695 NdrClientInitialize( PRPC_MESSAGE pRpcMessage, PMIDL_STUB_MESSAGE pStubMsg,
696 PMIDL_STUB_DESC pStubDesc, unsigned int ProcNum );
697RPCRTAPI void RPC_ENTRY
698 NdrClientInitializeNew( PRPC_MESSAGE pRpcMessage, PMIDL_STUB_MESSAGE pStubMsg,
699 PMIDL_STUB_DESC pStubDesc, unsigned int ProcNum );
700RPCRTAPI unsigned char* RPC_ENTRY
701 NdrServerInitialize( PRPC_MESSAGE pRpcMsg, PMIDL_STUB_MESSAGE pStubMsg, PMIDL_STUB_DESC pStubDesc );
702RPCRTAPI unsigned char* RPC_ENTRY
703 NdrServerInitializeNew( PRPC_MESSAGE pRpcMsg, PMIDL_STUB_MESSAGE pStubMsg, PMIDL_STUB_DESC pStubDesc );
704RPCRTAPI unsigned char* RPC_ENTRY
705 NdrServerInitializeUnmarshall( PMIDL_STUB_MESSAGE pStubMsg, PMIDL_STUB_DESC pStubDesc, PRPC_MESSAGE pRpcMsg );
706RPCRTAPI void RPC_ENTRY
707 NdrServerInitializeMarshall( PRPC_MESSAGE pRpcMsg, PMIDL_STUB_MESSAGE pStubMsg );
708RPCRTAPI void RPC_ENTRY
709 NdrServerMarshall( struct IRpcStubBuffer *pThis, struct IRpcChannelBuffer *pChannel, PMIDL_STUB_MESSAGE pStubMsg, PFORMAT_STRING pFormat );
710RPCRTAPI void RPC_ENTRY
711 NdrServerUnmarshall( struct IRpcChannelBuffer *pChannel, PRPC_MESSAGE pRpcMsg,
712 PMIDL_STUB_MESSAGE pStubMsg, PMIDL_STUB_DESC pStubDesc,
713 PFORMAT_STRING pFormat, void *pParamList );
714RPCRTAPI unsigned char* RPC_ENTRY
715 NdrGetBuffer( PMIDL_STUB_MESSAGE stubmsg, ULONG buflen, RPC_BINDING_HANDLE handle );
716RPCRTAPI void RPC_ENTRY
717 NdrFreeBuffer( PMIDL_STUB_MESSAGE pStubMsg );
718RPCRTAPI unsigned char* RPC_ENTRY
719 NdrSendReceive( PMIDL_STUB_MESSAGE stubmsg, unsigned char *buffer );
720
721RPCRTAPI unsigned char * RPC_ENTRY
722 NdrNsGetBuffer( PMIDL_STUB_MESSAGE pStubMsg, ULONG BufferLength, RPC_BINDING_HANDLE Handle );
723RPCRTAPI unsigned char * RPC_ENTRY
724 NdrNsSendReceive( PMIDL_STUB_MESSAGE pStubMsg, unsigned char *pBufferEnd, RPC_BINDING_HANDLE *pAutoHandle );
725
726RPCRTAPI RPC_STATUS RPC_ENTRY
727 NdrGetDcomProtocolVersion( PMIDL_STUB_MESSAGE pStubMsg, RPC_VERSION *pVersion );
728
729RPCRTAPI PFULL_PTR_XLAT_TABLES RPC_ENTRY
730 NdrFullPointerXlatInit( ULONG NumberOfPointers, XLAT_SIDE XlatSide );
731RPCRTAPI void RPC_ENTRY
732 NdrFullPointerXlatFree( PFULL_PTR_XLAT_TABLES pXlatTables );
733RPCRTAPI int RPC_ENTRY
734 NdrFullPointerQueryPointer( PFULL_PTR_XLAT_TABLES pXlatTables, void *pPointer,
735 unsigned char QueryType, ULONG *pRefId );
736RPCRTAPI int RPC_ENTRY
737 NdrFullPointerQueryRefId( PFULL_PTR_XLAT_TABLES pXlatTables, ULONG RefId,
738 unsigned char QueryType, void **ppPointer );
739RPCRTAPI void RPC_ENTRY
740 NdrFullPointerInsertRefId( PFULL_PTR_XLAT_TABLES pXlatTables, ULONG RefId, void *pPointer );
741RPCRTAPI int RPC_ENTRY
742 NdrFullPointerFree( PFULL_PTR_XLAT_TABLES pXlatTables, void *Pointer );
743
744RPCRTAPI void RPC_ENTRY
745 NdrRpcSsEnableAllocate( PMIDL_STUB_MESSAGE pMessage );
746RPCRTAPI void RPC_ENTRY
747 NdrRpcSsDisableAllocate( PMIDL_STUB_MESSAGE pMessage );
748RPCRTAPI void RPC_ENTRY
749 NdrRpcSmSetClientToOsf( PMIDL_STUB_MESSAGE pMessage );
750RPCRTAPI void * RPC_ENTRY
751 NdrRpcSmClientAllocate( SIZE_T Size ) __WINE_ALLOC_SIZE(1);
752RPCRTAPI void RPC_ENTRY
753 NdrRpcSmClientFree( void *NodeToFree );
754RPCRTAPI void * RPC_ENTRY
755 NdrRpcSsDefaultAllocate( SIZE_T Size ) __WINE_ALLOC_SIZE(1);
756RPCRTAPI void RPC_ENTRY
757 NdrRpcSsDefaultFree( void *NodeToFree );
758
759RPCRTAPI RPC_STATUS RPC_ENTRY
760 NdrGetUserMarshalInfo( ULONG *pFlags, ULONG InformationLevel, NDR_USER_MARSHAL_INFO *pMarshalInfo );
761
762#ifdef __cplusplus
763}
764#endif
765#endif /*__WINE_RPCNDR_H */
Note: See TracBrowser for help on using the repository browser.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette