e2b12f19643e1814ea40ae3ca785f8a9ceae52c1
[reactos.git] / reactos / include / reactos / idl / winspool.idl
1 /*
2 * PROJECT: ReactOS Spooler API
3 * LICENSE: GNU LGPL v2.1 or any later version as published by the Free Software Foundation
4 * PURPOSE: WIDL-compatible interface definition for the Spooler API
5 * COPYRIGHT: Copyright 2015 Colin Finck <colin@reactos.org>
6 */
7
8 #include <ms-dtyp.idl>
9
10 typedef [context_handle] void* WINSPOOL_PRINTER_HANDLE;
11 typedef [handle, string, unique] WCHAR* WINSPOOL_HANDLE;
12
13 typedef struct _DEVMODE_CONTAINER
14 {
15 DWORD cbBuf;
16 BYTE* pDevMode;
17 }
18 WINSPOOL_DEVMODE_CONTAINER;
19
20
21 [
22 uuid(12345678-1234-ABCD-EF00-0123456789AB),
23 version(1.0),
24 endpoint("ncacn_np:[\\pipe\\spoolss]"),
25 pointer_default(unique)
26 ]
27
28 interface winspool {
29 /* Function 0 */
30 DWORD _RpcEnumPrinters(
31 [in] DWORD Flags,
32 [in] WINSPOOL_HANDLE Name,
33 [in] DWORD Level,
34 [out] BYTE* pPrinterEnum,
35 [in] DWORD cbBuf,
36 [out] DWORD* pcbNeeded,
37 [out] DWORD* pcReturned
38 );
39
40 /* Function 1 */
41 DWORD _RpcOpenPrinter(
42 [in] WINSPOOL_HANDLE pPrinterName,
43 [out] WINSPOOL_PRINTER_HANDLE* phPrinter,
44 [in, string, unique] WCHAR* pDatatype,
45 [in] WINSPOOL_DEVMODE_CONTAINER* pDevModeContainer,
46 [in] DWORD AccessRequired
47 );
48 }