VirtualBox

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

Last change on this file since 30926 was 25949, checked in by vboxsync, 15 years ago

crOpenGL: update to wine 1.1.36 and disable unnecessary fbo state poll

  • Property svn:eol-style set to native
File size: 25.6 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;
109typedef INT64 hyper;
110typedef UINT64 MIDL_uhyper;
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
182typedef struct _MIDL_STUB_MESSAGE
183{
184 PRPC_MESSAGE RpcMsg;
185 unsigned char *Buffer;
186 unsigned char *BufferStart;
187 unsigned char *BufferEnd;
188 unsigned char *BufferMark;
189 ULONG BufferLength;
190 ULONG MemorySize;
191 unsigned char *Memory;
192 unsigned char IsClient;
193 unsigned char Pad;
194 unsigned short uFlags2;
195 int ReuseBuffer;
196 struct NDR_ALLOC_ALL_NODES_CONTEXT *pAllocAllNodesContext;
197 struct NDR_POINTER_QUEUE_STATE *pPointerQueueState;
198 int IgnoreEmbeddedPointers;
199 unsigned char *PointerBufferMark;
200 unsigned char CorrDespIncrement;
201 unsigned char uFlags;
202 unsigned short UniquePtrCount;
203 ULONG_PTR MaxCount;
204 ULONG Offset;
205 ULONG ActualCount;
206 void * (__WINE_ALLOC_SIZE(1) __RPC_API *pfnAllocate)(SIZE_T);
207 void (__RPC_API *pfnFree)(void *);
208 unsigned char *StackTop;
209 unsigned char *pPresentedType;
210 unsigned char *pTransmitType;
211 handle_t SavedHandle;
212 const struct _MIDL_STUB_DESC *StubDesc;
213 struct _FULL_PTR_XLAT_TABLES *FullPtrXlatTables;
214 ULONG FullPtrRefId;
215 ULONG PointerLength;
216 unsigned int fInDontFree:1;
217 unsigned int fDontCallFreeInst:1;
218 unsigned int fInOnlyParam:1;
219 unsigned int fHasReturn:1;
220 unsigned int fHasExtensions:1;
221 unsigned int fHasNewCorrDesc:1;
222 unsigned int fIsIn:1;
223 unsigned int fIsOut:1;
224 unsigned int fIsOicf:1;
225 unsigned int fBufferValid:1;
226 unsigned int fHasMemoryValidateCallback:1;
227 unsigned int fInFree:1;
228 unsigned int fNeedMCCP:1;
229 int fUnused:3;
230 int fUnused2:16;
231 DWORD dwDestContext;
232 void *pvDestContext;
233 NDR_SCONTEXT *SavedContextHandles;
234 LONG ParamNumber;
235 struct IRpcChannelBuffer *pRpcChannelBuffer;
236 PARRAY_INFO pArrayInfo;
237 ULONG *SizePtrCountArray;
238 ULONG *SizePtrOffsetArray;
239 ULONG *SizePtrLengthArray;
240 void *pArgQueue;
241 DWORD dwStubPhase;
242 void *LowStackMark;
243 PNDR_ASYNC_MESSAGE pAsyncMsg;
244 PNDR_CORRELATION_INFO pCorrInfo;
245 unsigned char *pCorrMemory;
246 void *pMemoryList;
247 CS_STUB_INFO *pCSInfo;
248 unsigned char *ConformanceMark;
249 unsigned char *VarianceMark;
250 INT_PTR Unused; /* BackingStoreLowMark on IA64 */
251 struct _NDR_PROC_CONTEXT *pContext;
252 void* ContextHandleHash;
253 void* pUserMarshalList;
254 INT_PTR Reserved51_3;
255 INT_PTR Reserved51_4;
256 INT_PTR Reserved51_5;
257} MIDL_STUB_MESSAGE, *PMIDL_STUB_MESSAGE;
258
259typedef void * (__RPC_API * GENERIC_BINDING_ROUTINE)(void *);
260typedef void (__RPC_API * GENERIC_UNBIND_ROUTINE)(void *, unsigned char *);
261
262typedef struct _GENERIC_BINDING_ROUTINE_PAIR
263{
264 GENERIC_BINDING_ROUTINE pfnBind;
265 GENERIC_UNBIND_ROUTINE pfnUnbind;
266} GENERIC_BINDING_ROUTINE_PAIR, *PGENERIC_BINDING_ROUTINE_PAIR;
267
268typedef struct __GENERIC_BINDING_INFO
269{
270 void *pObj;
271 unsigned int Size;
272 GENERIC_BINDING_ROUTINE pfnBind;
273 GENERIC_UNBIND_ROUTINE pfnUnbind;
274} GENERIC_BINDING_INFO, *PGENERIC_BINDING_INFO;
275
276typedef void (__RPC_USER *XMIT_HELPER_ROUTINE)(PMIDL_STUB_MESSAGE);
277
278typedef struct _XMIT_ROUTINE_QUINTUPLE
279{
280 XMIT_HELPER_ROUTINE pfnTranslateToXmit;
281 XMIT_HELPER_ROUTINE pfnTranslateFromXmit;
282 XMIT_HELPER_ROUTINE pfnFreeXmit;
283 XMIT_HELPER_ROUTINE pfnFreeInst;
284} XMIT_ROUTINE_QUINTUPLE, *PXMIT_ROUTINE_QUINTUPLE;
285
286typedef ULONG (__RPC_USER *USER_MARSHAL_SIZING_ROUTINE)(ULONG *, ULONG, void *);
287typedef unsigned char * (__RPC_USER *USER_MARSHAL_MARSHALLING_ROUTINE)(ULONG *, unsigned char *, void *);
288typedef unsigned char * (__RPC_USER *USER_MARSHAL_UNMARSHALLING_ROUTINE)(ULONG *, unsigned char *, void *);
289typedef void (__RPC_USER *USER_MARSHAL_FREEING_ROUTINE)(ULONG *, void *);
290
291typedef struct _USER_MARSHAL_ROUTINE_QUADRUPLE
292{
293 USER_MARSHAL_SIZING_ROUTINE pfnBufferSize;
294 USER_MARSHAL_MARSHALLING_ROUTINE pfnMarshall;
295 USER_MARSHAL_UNMARSHALLING_ROUTINE pfnUnmarshall;
296 USER_MARSHAL_FREEING_ROUTINE pfnFree;
297} USER_MARSHAL_ROUTINE_QUADRUPLE;
298
299/* 'USRC' */
300#define USER_MARSHAL_CB_SIGNATURE \
301 ( ( (DWORD)'U' << 24 ) | ( (DWORD)'S' << 16 ) | \
302 ( (DWORD)'R' << 8 ) | ( (DWORD)'C' ) )
303
304typedef enum
305{
306 USER_MARSHAL_CB_BUFFER_SIZE,
307 USER_MARSHAL_CB_MARSHALL,
308 USER_MARSHAL_CB_UNMARSHALL,
309 USER_MARSHAL_CB_FREE
310} USER_MARSHAL_CB_TYPE;
311
312typedef struct _USER_MARSHAL_CB
313{
314 ULONG Flags;
315 PMIDL_STUB_MESSAGE pStubMsg;
316 PFORMAT_STRING pReserve;
317 ULONG Signature;
318 USER_MARSHAL_CB_TYPE CBType;
319 PFORMAT_STRING pFormat;
320 PFORMAT_STRING pTypeFormat;
321} USER_MARSHAL_CB;
322
323#define USER_CALL_CTXT_MASK(f) ((f) & 0x00ff)
324#define USER_CALL_AUX_MASK(f) ((f) & 0xff00)
325#define GET_USER_DATA_REP(f) HIWORD(f)
326
327#define USER_CALL_IS_ASYNC 0x0100
328#define USER_CALL_NEW_CORRELATION_DESC 0x0200
329
330typedef struct _MALLOC_FREE_STRUCT
331{
332 void * (__WINE_ALLOC_SIZE(1) __RPC_USER *pfnAllocate)(SIZE_T);
333 void (__RPC_USER *pfnFree)(void *);
334} MALLOC_FREE_STRUCT;
335
336typedef struct _COMM_FAULT_OFFSETS
337{
338 short CommOffset;
339 short FaultOffset;
340} COMM_FAULT_OFFSETS;
341
342typedef struct _MIDL_STUB_DESC
343{
344 void *RpcInterfaceInformation;
345 void * (__WINE_ALLOC_SIZE(1) __RPC_API *pfnAllocate)(SIZE_T);
346 void (__RPC_API *pfnFree)(void *);
347 union {
348 handle_t *pAutoHandle;
349 handle_t *pPrimitiveHandle;
350 PGENERIC_BINDING_INFO pGenericBindingInfo;
351 } IMPLICIT_HANDLE_INFO;
352 const NDR_RUNDOWN *apfnNdrRundownRoutines;
353 const GENERIC_BINDING_ROUTINE_PAIR *aGenericBindingRoutinePairs;
354 const EXPR_EVAL *apfnExprEval;
355 const XMIT_ROUTINE_QUINTUPLE *aXmitQuintuple;
356 const unsigned char *pFormatTypes;
357 int fCheckBounds;
358 ULONG Version;
359 MALLOC_FREE_STRUCT *pMallocFreeStruct;
360 LONG MIDLVersion;
361 const COMM_FAULT_OFFSETS *CommFaultOffsets;
362 const USER_MARSHAL_ROUTINE_QUADRUPLE *aUserMarshalQuadruple;
363 const NDR_NOTIFY_ROUTINE *NotifyRoutineTable;
364 ULONG_PTR mFlags;
365 ULONG_PTR Reserved3;
366 ULONG_PTR Reserved4;
367 ULONG_PTR Reserved5;
368} MIDL_STUB_DESC;
369typedef const MIDL_STUB_DESC *PMIDL_STUB_DESC;
370
371typedef struct _MIDL_FORMAT_STRING
372{
373 short Pad;
374#if defined(__GNUC__)
375 unsigned char Format[0];
376#else
377 unsigned char Format[1];
378#endif
379} MIDL_FORMAT_STRING;
380
381typedef struct _MIDL_SYNTAX_INFO
382{
383 RPC_SYNTAX_IDENTIFIER TransferSyntax;
384 RPC_DISPATCH_TABLE* DispatchTable;
385 PFORMAT_STRING ProcString;
386 const unsigned short* FmtStringOffset;
387 PFORMAT_STRING TypeString;
388 const void* aUserMarshalQuadruple;
389 ULONG_PTR pReserved1;
390 ULONG_PTR pReserved2;
391} MIDL_SYNTAX_INFO, *PMIDL_SYNTAX_INFO;
392
393typedef void (__RPC_API *STUB_THUNK)( PMIDL_STUB_MESSAGE );
394
395#ifdef WINE_STRICT_PROTOTYPES
396typedef LONG (__RPC_API *SERVER_ROUTINE)(void);
397#else
398typedef LONG (__RPC_API *SERVER_ROUTINE)();
399#endif
400
401typedef struct _MIDL_SERVER_INFO_
402{
403 PMIDL_STUB_DESC pStubDesc;
404 const SERVER_ROUTINE *DispatchTable;
405 PFORMAT_STRING ProcString;
406 const unsigned short *FmtStringOffset;
407 const STUB_THUNK *ThunkTable;
408 PRPC_SYNTAX_IDENTIFIER pTransferSyntax;
409 ULONG_PTR nCount;
410 PMIDL_SYNTAX_INFO pSyntaxInfo;
411} MIDL_SERVER_INFO, *PMIDL_SERVER_INFO;
412
413typedef struct _MIDL_STUBLESS_PROXY_INFO
414{
415 PMIDL_STUB_DESC pStubDesc;
416 PFORMAT_STRING ProcFormatString;
417 const unsigned short *FormatStringOffset;
418 PRPC_SYNTAX_IDENTIFIER pTransferSyntax;
419 ULONG_PTR nCount;
420 PMIDL_SYNTAX_INFO pSyntaxInfo;
421} MIDL_STUBLESS_PROXY_INFO, *PMIDL_STUBLESS_PROXY_INFO;
422
423typedef union _CLIENT_CALL_RETURN
424{
425 void *Pointer;
426 LONG_PTR Simple;
427} CLIENT_CALL_RETURN;
428
429typedef enum {
430 STUB_UNMARSHAL,
431 STUB_CALL_SERVER,
432 STUB_MARSHAL,
433 STUB_CALL_SERVER_NO_HRESULT
434} STUB_PHASE;
435
436typedef enum {
437 PROXY_CALCSIZE,
438 PROXY_GETBUFFER,
439 PROXY_MARSHAL,
440 PROXY_SENDRECEIVE,
441 PROXY_UNMARSHAL
442} PROXY_PHASE;
443
444typedef enum {
445 XLAT_SERVER = 1,
446 XLAT_CLIENT
447} XLAT_SIDE;
448
449typedef struct _FULL_PTR_TO_REFID_ELEMENT {
450 struct _FULL_PTR_TO_REFID_ELEMENT *Next;
451 void *Pointer;
452 ULONG RefId;
453 unsigned char State;
454} FULL_PTR_TO_REFID_ELEMENT, *PFULL_PTR_TO_REFID_ELEMENT;
455
456/* Full pointer translation tables */
457typedef struct _FULL_PTR_XLAT_TABLES {
458 struct {
459 void **XlatTable;
460 unsigned char *StateTable;
461 ULONG NumberOfEntries;
462 } RefIdToPointer;
463
464 struct {
465 PFULL_PTR_TO_REFID_ELEMENT *XlatTable;
466 ULONG NumberOfBuckets;
467 ULONG HashMask;
468 } PointerToRefId;
469
470 ULONG NextRefId;
471 XLAT_SIDE XlatSide;
472} FULL_PTR_XLAT_TABLES, *PFULL_PTR_XLAT_TABLES;
473
474struct IRpcStubBuffer;
475
476typedef ULONG error_status_t;
477typedef void * NDR_CCONTEXT;
478
479typedef struct _SCONTEXT_QUEUE {
480 ULONG NumberOfObjects;
481 NDR_SCONTEXT *ArrayOfObjects;
482} SCONTEXT_QUEUE, *PSCONTEXT_QUEUE;
483
484typedef struct _NDR_USER_MARSHAL_INFO_LEVEL1
485{
486 void *Buffer;
487 ULONG BufferSize;
488 void * (__WINE_ALLOC_SIZE(1) __RPC_API *pfnAllocate)(SIZE_T);
489 void (__RPC_API *pfnFree)(void *);
490 struct IRpcChannelBuffer *pRpcChannelBuffer;
491 ULONG_PTR Reserved[5];
492} NDR_USER_MARSHAL_INFO_LEVEL1;
493
494typedef struct _NDR_USER_MARSHAL_INFO
495{
496 ULONG InformationLevel;
497 union
498 {
499 NDR_USER_MARSHAL_INFO_LEVEL1 Level1;
500 } DUMMYUNIONNAME1;
501} NDR_USER_MARSHAL_INFO;
502
503/* Context Handles */
504
505RPCRTAPI RPC_BINDING_HANDLE RPC_ENTRY
506 NDRCContextBinding( NDR_CCONTEXT CContext );
507
508RPCRTAPI void RPC_ENTRY
509 NDRCContextMarshall( NDR_CCONTEXT CContext, void *pBuff );
510
511RPCRTAPI void RPC_ENTRY
512 NDRCContextUnmarshall( NDR_CCONTEXT *pCContext, RPC_BINDING_HANDLE hBinding,
513 void *pBuff, ULONG DataRepresentation );
514
515RPCRTAPI void RPC_ENTRY
516 NDRSContextMarshall( NDR_SCONTEXT CContext, void *pBuff, NDR_RUNDOWN userRunDownIn );
517
518RPCRTAPI NDR_SCONTEXT RPC_ENTRY
519 NDRSContextUnmarshall( void *pBuff, ULONG DataRepresentation );
520
521RPCRTAPI void RPC_ENTRY
522 NDRSContextMarshallEx( RPC_BINDING_HANDLE BindingHandle, NDR_SCONTEXT CContext,
523 void *pBuff, NDR_RUNDOWN userRunDownIn );
524
525RPCRTAPI void RPC_ENTRY
526 NDRSContextMarshall2( RPC_BINDING_HANDLE BindingHandle, NDR_SCONTEXT CContext,
527 void *pBuff, NDR_RUNDOWN userRunDownIn, void * CtxGuard,
528 ULONG Flags );
529
530RPCRTAPI NDR_SCONTEXT RPC_ENTRY
531 NDRSContextUnmarshallEx( RPC_BINDING_HANDLE BindingHandle, void *pBuff,
532 ULONG DataRepresentation );
533
534RPCRTAPI NDR_SCONTEXT RPC_ENTRY
535 NDRSContextUnmarshall2( RPC_BINDING_HANDLE BindingHandle, void *pBuff,
536 ULONG DataRepresentation, void *CtxGuard,
537 ULONG Flags );
538
539RPCRTAPI void RPC_ENTRY
540 NdrClientContextMarshall ( PMIDL_STUB_MESSAGE pStubMsg, NDR_CCONTEXT ContextHandle, int fCheck );
541
542RPCRTAPI void RPC_ENTRY
543 NdrClientContextUnmarshall( PMIDL_STUB_MESSAGE pStubMsg, NDR_CCONTEXT* pContextHandle,
544 RPC_BINDING_HANDLE BindHandle );
545
546RPCRTAPI void RPC_ENTRY
547 NdrServerContextMarshall ( PMIDL_STUB_MESSAGE pStubMsg, NDR_SCONTEXT ContextHandle, NDR_RUNDOWN RundownRoutine );
548
549RPCRTAPI NDR_SCONTEXT RPC_ENTRY
550 NdrServerContextUnmarshall( PMIDL_STUB_MESSAGE pStubMsg );
551
552RPCRTAPI void RPC_ENTRY
553 NdrContextHandleSize( PMIDL_STUB_MESSAGE pStubMsg, unsigned char* pMemory, PFORMAT_STRING pFormat );
554
555RPCRTAPI NDR_SCONTEXT RPC_ENTRY
556 NdrContextHandleInitialize( PMIDL_STUB_MESSAGE pStubMsg, PFORMAT_STRING pFormat );
557
558RPCRTAPI void RPC_ENTRY
559 NdrServerContextNewMarshall( PMIDL_STUB_MESSAGE pStubMsg, NDR_SCONTEXT ContextHandle,
560 NDR_RUNDOWN RundownRoutine, PFORMAT_STRING pFormat );
561
562RPCRTAPI NDR_SCONTEXT RPC_ENTRY
563 NdrServerContextNewUnmarshall( PMIDL_STUB_MESSAGE pStubMsg, PFORMAT_STRING pFormat );
564
565RPCRTAPI RPC_STATUS RPC_ENTRY
566 RpcSmDestroyClientContext( void **ContextHandle );
567
568RPCRTAPI void RPC_ENTRY
569 RpcSsDestroyClientContext( void **ContextHandle );
570
571RPCRTAPI void RPC_ENTRY
572 NdrSimpleTypeMarshall( PMIDL_STUB_MESSAGE pStubMsg, unsigned char* pMemory, unsigned char FormatChar );
573RPCRTAPI void RPC_ENTRY
574 NdrSimpleTypeUnmarshall( PMIDL_STUB_MESSAGE pStubMsg, unsigned char* pMemory, unsigned char FormatChar );
575
576RPCRTAPI unsigned char* RPC_ENTRY
577 NdrByteCountPointerMarshall( PMIDL_STUB_MESSAGE pStubMsg, unsigned char* pMemory, PFORMAT_STRING pFormat );
578RPCRTAPI unsigned char* RPC_ENTRY
579 NdrByteCountPointerUnmarshall( PMIDL_STUB_MESSAGE pStubMsg, unsigned char** ppMemory, PFORMAT_STRING pFormat, unsigned char fMustAlloc );
580RPCRTAPI void RPC_ENTRY
581 NdrByteCountPointerBufferSize( PMIDL_STUB_MESSAGE pStubMsg, unsigned char* pMemory, PFORMAT_STRING pFormat );
582RPCRTAPI void RPC_ENTRY
583 NdrByteCountPointerFree( PMIDL_STUB_MESSAGE pStubMsg, unsigned char* pMemory, PFORMAT_STRING pFormat );
584
585RPCRTAPI unsigned char* RPC_ENTRY
586 NdrRangeUnmarshall( PMIDL_STUB_MESSAGE pStubMsg, unsigned char** ppMemory, PFORMAT_STRING pFormat, unsigned char fMustAlloc );
587
588/* while MS declares each prototype separately, I prefer to use macros for this kind of thing instead */
589#define SIMPLE_TYPE_MARSHAL(type) \
590RPCRTAPI unsigned char* RPC_ENTRY \
591 Ndr##type##Marshall( PMIDL_STUB_MESSAGE pStubMsg, unsigned char* pMemory, PFORMAT_STRING pFormat ); \
592RPCRTAPI unsigned char* RPC_ENTRY \
593 Ndr##type##Unmarshall( PMIDL_STUB_MESSAGE pStubMsg, unsigned char** ppMemory, PFORMAT_STRING pFormat, unsigned char fMustAlloc ); \
594RPCRTAPI void RPC_ENTRY \
595 Ndr##type##BufferSize( PMIDL_STUB_MESSAGE pStubMsg, unsigned char* pMemory, PFORMAT_STRING pFormat ); \
596RPCRTAPI ULONG RPC_ENTRY \
597 Ndr##type##MemorySize( PMIDL_STUB_MESSAGE pStubMsg, PFORMAT_STRING pFormat );
598
599#define TYPE_MARSHAL(type) \
600 SIMPLE_TYPE_MARSHAL(type) \
601RPCRTAPI void RPC_ENTRY \
602 Ndr##type##Free( PMIDL_STUB_MESSAGE pStubMsg, unsigned char* pMemory, PFORMAT_STRING pFormat );
603
604TYPE_MARSHAL(Pointer)
605TYPE_MARSHAL(SimpleStruct)
606TYPE_MARSHAL(ConformantStruct)
607TYPE_MARSHAL(ConformantVaryingStruct)
608TYPE_MARSHAL(ComplexStruct)
609TYPE_MARSHAL(FixedArray)
610TYPE_MARSHAL(ConformantArray)
611TYPE_MARSHAL(ConformantVaryingArray)
612TYPE_MARSHAL(VaryingArray)
613TYPE_MARSHAL(ComplexArray)
614TYPE_MARSHAL(EncapsulatedUnion)
615TYPE_MARSHAL(NonEncapsulatedUnion)
616TYPE_MARSHAL(XmitOrRepAs)
617TYPE_MARSHAL(UserMarshal)
618TYPE_MARSHAL(InterfacePointer)
619
620SIMPLE_TYPE_MARSHAL(ConformantString)
621SIMPLE_TYPE_MARSHAL(NonConformantString)
622
623#undef TYPE_MARSHAL
624#undef SIMPLE_TYPE_MARSHAL
625
626RPCRTAPI void RPC_ENTRY
627 NdrCorrelationInitialize( PMIDL_STUB_MESSAGE pStubMsg, void *pMemory, ULONG CacheSize, ULONG flags );
628RPCRTAPI void RPC_ENTRY
629 NdrCorrelationPass( PMIDL_STUB_MESSAGE pStubMsg );
630RPCRTAPI void RPC_ENTRY
631 NdrCorrelationFree( PMIDL_STUB_MESSAGE pStubMsg );
632
633RPCRTAPI void RPC_ENTRY
634 NdrConvert2( PMIDL_STUB_MESSAGE pStubMsg, PFORMAT_STRING pFormat, LONG NumberParams );
635RPCRTAPI void RPC_ENTRY
636 NdrConvert( PMIDL_STUB_MESSAGE pStubMsg, PFORMAT_STRING pFormat );
637
638#define USER_MARSHAL_FC_BYTE 1
639#define USER_MARSHAL_FC_CHAR 2
640#define USER_MARSHAL_FC_SMALL 3
641#define USER_MARSHAL_FC_USMALL 4
642#define USER_MARSHAL_FC_WCHAR 5
643#define USER_MARSHAL_FC_SHORT 6
644#define USER_MARSHAL_FC_USHORT 7
645#define USER_MARSHAL_FC_LONG 8
646#define USER_MARSHAL_FC_ULONG 9
647#define USER_MARSHAL_FC_FLOAT 10
648#define USER_MARSHAL_FC_HYPER 11
649#define USER_MARSHAL_FC_DOUBLE 12
650
651RPCRTAPI unsigned char* RPC_ENTRY
652 NdrUserMarshalSimpleTypeConvert( ULONG *pFlags, unsigned char *pBuffer, unsigned char FormatChar );
653
654/* Note: this should return a CLIENT_CALL_RETURN, but calling convention for
655 * returning structures/unions is different between Windows and gcc on i386. */
656LONG_PTR RPC_VAR_ENTRY
657 NdrClientCall2( PMIDL_STUB_DESC pStubDescriptor, PFORMAT_STRING pFormat, ... );
658LONG_PTR RPC_VAR_ENTRY
659 NdrClientCall( PMIDL_STUB_DESC pStubDescriptor, PFORMAT_STRING pFormat, ... );
660LONG_PTR RPC_VAR_ENTRY
661 NdrAsyncClientCall( PMIDL_STUB_DESC pStubDescriptor, PFORMAT_STRING pFormat, ... );
662LONG_PTR RPC_VAR_ENTRY
663 NdrDcomAsyncClientCall( PMIDL_STUB_DESC pStubDescriptor, PFORMAT_STRING pFormat, ... );
664
665RPCRTAPI void RPC_ENTRY
666 NdrServerCall2( PRPC_MESSAGE pRpcMsg );
667RPCRTAPI void RPC_ENTRY
668 NdrServerCall( PRPC_MESSAGE pRpcMsg );
669RPCRTAPI void RPC_ENTRY
670 NdrAsyncServerCall( PRPC_MESSAGE pRpcMsg );
671
672RPCRTAPI LONG RPC_ENTRY
673 NdrStubCall2( struct IRpcStubBuffer* pThis, struct IRpcChannelBuffer* pChannel, PRPC_MESSAGE pRpcMsg, DWORD * pdwStubPhase );
674RPCRTAPI LONG RPC_ENTRY
675 NdrStubCall( struct IRpcStubBuffer* pThis, struct IRpcChannelBuffer* pChannel, PRPC_MESSAGE pRpcMsg, DWORD * pdwStubPhase );
676RPCRTAPI LONG RPC_ENTRY
677 NdrAsyncStubCall( struct IRpcStubBuffer* pThis, struct IRpcChannelBuffer* pChannel, PRPC_MESSAGE pRpcMsg, DWORD * pdwStubPhase );
678RPCRTAPI LONG RPC_ENTRY
679 NdrDcomAsyncStubCall( struct IRpcStubBuffer* pThis, struct IRpcChannelBuffer* pChannel, PRPC_MESSAGE pRpcMsg, DWORD * pdwStubPhase );
680
681RPCRTAPI void* RPC_ENTRY
682 NdrAllocate( PMIDL_STUB_MESSAGE pStubMsg, SIZE_T Len ) __WINE_ALLOC_SIZE(2);
683
684RPCRTAPI void RPC_ENTRY
685 NdrClearOutParameters( PMIDL_STUB_MESSAGE pStubMsg, PFORMAT_STRING pFormat, void *ArgAddr );
686
687RPCRTAPI RPC_STATUS RPC_ENTRY
688 NdrMapCommAndFaultStatus( PMIDL_STUB_MESSAGE pStubMsg, ULONG *pCommStatus,
689 ULONG *pFaultStatus, RPC_STATUS Status_ );
690
691RPCRTAPI void* RPC_ENTRY
692 NdrOleAllocate( SIZE_T Size ) __WINE_ALLOC_SIZE(1);
693RPCRTAPI void RPC_ENTRY
694 NdrOleFree( void* NodeToFree );
695
696RPCRTAPI void RPC_ENTRY
697 NdrClientInitialize( PRPC_MESSAGE pRpcMessage, PMIDL_STUB_MESSAGE pStubMsg,
698 PMIDL_STUB_DESC pStubDesc, unsigned int ProcNum );
699RPCRTAPI void RPC_ENTRY
700 NdrClientInitializeNew( PRPC_MESSAGE pRpcMessage, PMIDL_STUB_MESSAGE pStubMsg,
701 PMIDL_STUB_DESC pStubDesc, unsigned int ProcNum );
702RPCRTAPI unsigned char* RPC_ENTRY
703 NdrServerInitialize( PRPC_MESSAGE pRpcMsg, PMIDL_STUB_MESSAGE pStubMsg, PMIDL_STUB_DESC pStubDesc );
704RPCRTAPI unsigned char* RPC_ENTRY
705 NdrServerInitializeNew( PRPC_MESSAGE pRpcMsg, PMIDL_STUB_MESSAGE pStubMsg, PMIDL_STUB_DESC pStubDesc );
706RPCRTAPI unsigned char* RPC_ENTRY
707 NdrServerInitializeUnmarshall( PMIDL_STUB_MESSAGE pStubMsg, PMIDL_STUB_DESC pStubDesc, PRPC_MESSAGE pRpcMsg );
708RPCRTAPI void RPC_ENTRY
709 NdrServerInitializeMarshall( PRPC_MESSAGE pRpcMsg, PMIDL_STUB_MESSAGE pStubMsg );
710RPCRTAPI void RPC_ENTRY
711 NdrServerMarshall( struct IRpcStubBuffer *pThis, struct IRpcChannelBuffer *pChannel, PMIDL_STUB_MESSAGE pStubMsg, PFORMAT_STRING pFormat );
712RPCRTAPI void RPC_ENTRY
713 NdrServerUnmarshall( struct IRpcChannelBuffer *pChannel, PRPC_MESSAGE pRpcMsg,
714 PMIDL_STUB_MESSAGE pStubMsg, PMIDL_STUB_DESC pStubDesc,
715 PFORMAT_STRING pFormat, void *pParamList );
716RPCRTAPI unsigned char* RPC_ENTRY
717 NdrGetBuffer( PMIDL_STUB_MESSAGE stubmsg, ULONG buflen, RPC_BINDING_HANDLE handle );
718RPCRTAPI void RPC_ENTRY
719 NdrFreeBuffer( PMIDL_STUB_MESSAGE pStubMsg );
720RPCRTAPI unsigned char* RPC_ENTRY
721 NdrSendReceive( PMIDL_STUB_MESSAGE stubmsg, unsigned char *buffer );
722
723RPCRTAPI unsigned char * RPC_ENTRY
724 NdrNsGetBuffer( PMIDL_STUB_MESSAGE pStubMsg, ULONG BufferLength, RPC_BINDING_HANDLE Handle );
725RPCRTAPI unsigned char * RPC_ENTRY
726 NdrNsSendReceive( PMIDL_STUB_MESSAGE pStubMsg, unsigned char *pBufferEnd, RPC_BINDING_HANDLE *pAutoHandle );
727
728RPCRTAPI RPC_STATUS RPC_ENTRY
729 NdrGetDcomProtocolVersion( PMIDL_STUB_MESSAGE pStubMsg, RPC_VERSION *pVersion );
730
731RPCRTAPI PFULL_PTR_XLAT_TABLES RPC_ENTRY
732 NdrFullPointerXlatInit( ULONG NumberOfPointers, XLAT_SIDE XlatSide );
733RPCRTAPI void RPC_ENTRY
734 NdrFullPointerXlatFree( PFULL_PTR_XLAT_TABLES pXlatTables );
735RPCRTAPI int RPC_ENTRY
736 NdrFullPointerQueryPointer( PFULL_PTR_XLAT_TABLES pXlatTables, void *pPointer,
737 unsigned char QueryType, ULONG *pRefId );
738RPCRTAPI int RPC_ENTRY
739 NdrFullPointerQueryRefId( PFULL_PTR_XLAT_TABLES pXlatTables, ULONG RefId,
740 unsigned char QueryType, void **ppPointer );
741RPCRTAPI void RPC_ENTRY
742 NdrFullPointerInsertRefId( PFULL_PTR_XLAT_TABLES pXlatTables, ULONG RefId, void *pPointer );
743RPCRTAPI int RPC_ENTRY
744 NdrFullPointerFree( PFULL_PTR_XLAT_TABLES pXlatTables, void *Pointer );
745
746RPCRTAPI void RPC_ENTRY
747 NdrRpcSsEnableAllocate( PMIDL_STUB_MESSAGE pMessage );
748RPCRTAPI void RPC_ENTRY
749 NdrRpcSsDisableAllocate( PMIDL_STUB_MESSAGE pMessage );
750RPCRTAPI void RPC_ENTRY
751 NdrRpcSmSetClientToOsf( PMIDL_STUB_MESSAGE pMessage );
752RPCRTAPI void * RPC_ENTRY
753 NdrRpcSmClientAllocate( SIZE_T Size ) __WINE_ALLOC_SIZE(1);
754RPCRTAPI void RPC_ENTRY
755 NdrRpcSmClientFree( void *NodeToFree );
756RPCRTAPI void * RPC_ENTRY
757 NdrRpcSsDefaultAllocate( SIZE_T Size ) __WINE_ALLOC_SIZE(1);
758RPCRTAPI void RPC_ENTRY
759 NdrRpcSsDefaultFree( void *NodeToFree );
760
761RPCRTAPI RPC_STATUS RPC_ENTRY
762 NdrGetUserMarshalInfo( ULONG *pFlags, ULONG InformationLevel, NDR_USER_MARSHAL_INFO *pMarshalInfo );
763
764#ifdef __cplusplus
765}
766#endif
767#endif /*__WINE_RPCNDR_H */
Note: See TracBrowser for help on using the repository browser.

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