xref: /titanic_44/usr/src/uts/common/smbsrv/ndl/spoolss.ndl (revision 6a634c9dca3093f3922e4b7ab826d7bdf17bf78e)
1/*
2 * CDDL HEADER START
3 *
4 * The contents of this file are subject to the terms of the
5 * Common Development and Distribution License (the "License").
6 * You may not use this file except in compliance with the License.
7 *
8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 * or http://www.opensolaris.org/os/licensing.
10 * See the License for the specific language governing permissions
11 * and limitations under the License.
12 *
13 * When distributing Covered Code, include this CDDL HEADER in each
14 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 * If applicable, add the following below this CDDL HEADER, with the
16 * fields enclosed by brackets "[]" replaced with your own identifying
17 * information: Portions Copyright [yyyy] [name of copyright owner]
18 *
19 * CDDL HEADER END
20 */
21/*
22 * Copyright (c) 2007, 2010, Oracle and/or its affiliates. All rights reserved.
23 */
24
25#ifndef _SPOOLSS_NDL_
26#define	_SPOOLSS_NDL_
27
28#include "ndrtypes.ndl"
29#include "security.ndl"
30
31#define TABLE_STRING 1
32#define TABLE_DWORD  2
33#define TABLE_TIME   3
34#define TABLE_DEVMODE 4
35#define TABLE_SECURITY_DESCRIPTOR 5
36
37#define SPOOLSS_OPNUM_EnumPrinters			0x00
38#define SPOOLSS_OPNUM_OpenPrinter			0x01
39#define SPOOLSS_OPNUM_GetJob				0x03
40#define SPOOLSS_OPNUM_EnumJobs				0x04
41#define SPOOLSS_OPNUM_DeletePrinter			0x06
42#define SPOOLSS_OPNUM_GetPrinter			0x08
43#define SPOOLSS_OPNUM_GetPrinterDriver			0x0b
44#define SPOOLSS_OPNUM_DeletePrinterDriver		0x0d
45#define SPOOLSS_OPNUM_StartDocPrinter			0x11
46#define SPOOLSS_OPNUM_StartPagePrinter			0x12
47#define SPOOLSS_OPNUM_WritePrinter			0x13
48#define SPOOLSS_OPNUM_EndPagePrinter			0x14
49#define SPOOLSS_OPNUM_AbortPrinter			0x15
50#define SPOOLSS_OPNUM_AddJob				0x18
51#define SPOOLSS_OPNUM_ScheduleJob			0x19
52#define SPOOLSS_OPNUM_GetPrinterData			0x1a
53#define SPOOLSS_OPNUM_ClosePrinter			0x1d
54#define SPOOLSS_OPNUM_AddForm				0x1e
55#define SPOOLSS_OPNUM_DeleteForm			0x1f
56#define SPOOLSS_OPNUM_EndDocPrinter			0x17
57#define SPOOLSS_OPNUM_EnumForms				0x22
58#define SPOOLSS_OPNUM_EnumPorts				0x23
59#define	SPOOLSS_OPNUM_EnumMonitor			0x24
60#define SPOOLSS_OPNUM_DeletePort			0x27
61#define SPOOLSS_OPNUM_CreatePrinterIC			0x28
62#define	SPOOLSS_OPNUM_AddMonitor			0x2e
63#define	SPOOLSS_OPNUM_DeleteMonitor			0x2f
64#define SPOOLSS_OPNUM_ResetPrinter			0x34
65#define SPOOLSS_OPNUM_GetPrinterDriver2			0x35
66#define SPOOLSS_OPNUM_FCPN				0x38
67#define SPOOLSS_OPNUM_ReplyOpenPrinter			0x3a
68#define SPOOLSS_OPNUM_ReplyClosePrinter			0x3c
69#define SPOOLSS_OPNUM_AddPortEx				0x3d
70#define SPOOLSS_OPNUM_RFFPCNEX				0x41
71#define SPOOLSS_OPNUM_RRPCN				0x42
72#define SPOOLSS_OPNUM_RFNPCNEX				0x43
73#define SPOOLSS_OPNUM_OpenPrinterEx			0x45
74#define SPOOLSS_OPNUM_SetPort				0x47
75#define SPOOLSS_OPNUM_EnumPrinterData			0x48
76#define SPOOLSS_OPNUM_EnumPrinterDataEx			0x4f
77#define SPOOLSS_OPNUM_EnumPrinterKey			0x50
78
79CONTEXT_HANDLE(spoolss_handle) spoolss_handle_t;
80
81struct spoolssDevmodeContainer {
82	BYTE 	DevContCount;
83  SIZE_IS(DevContCount)
84  	BYTE	*DevMode;
85};
86
87
88struct spoolss_DeviceMode {
89	BYTE devicename[64];
90	WORD specversion;
91	WORD driverversion;
92	WORD size;
93	WORD driverextra_length;
94	DWORD	fields;
95	WORD orientation;
96	WORD papersize;
97	WORD paperlength;
98	WORD paperwidth;
99	WORD scale;
100	WORD copies;
101	WORD defaultsource;
102	WORD printquality;
103	WORD color;
104	WORD duplex;
105	WORD yresolution;
106	WORD ttoption;
107	WORD collate;
108	BYTE formname[64];
109	WORD logpixels;
110	DWORD	bitsperpel;
111	DWORD	pelswidth;
112	DWORD	pelsheight;
113	DWORD	displayflags;
114	DWORD	displayfrequency;
115	DWORD	icmmethod;
116	DWORD	icmintent;
117	DWORD	mediatype;
118	DWORD	dithertype;
119	DWORD	reserved1;
120	DWORD	reserved2;
121	DWORD	panningwidth;
122	DWORD	panningheight;
123	struct spoolssDevmodeContainer driverextra_data;
124};
125
126OPERATION(SPOOLSS_OPNUM_CreatePrinterIC)
127struct spoolss_CreatePrinterIC {
128	IN	spoolss_handle_t handle;
129	OUT	spoolss_handle_t gdi_handle;
130	IN	struct spoolssDevmodeContainer dmodeContainer;
131	OUT	DWORD status;
132};
133
134OPERATION(SPOOLSS_OPNUM_OpenPrinter)
135struct spoolss_OpenPrinter {
136	IN	LPTSTR printer_name;
137	OUT	spoolss_handle_t handle;
138	IN	LPTSTR data_type;
139	/* IN	struct spoolssDevmodeContainer dmodeContainer; */
140	/* IN	DWORD AccessRequired; */
141	OUT	DWORD status;
142};
143
144OPERATION(SPOOLSS_OPNUM_EnumJobs)
145struct spoolss_EnumJobs {
146	IN	spoolss_handle_t handle;
147	IN	DWORD FirstJob;
148	IN	DWORD NoJobs;
149	IN	DWORD level;
150	IN	DWORD Buf2;
151	IN	DWORD 	BufCount;
152		SIZE_IS(BufCount)
153  	OUT		BYTE *pJob;
154	OUT	DWORD needed;
155	OUT	DWORD needed2;
156	OUT	DWORD status;
157};
158
159OPERATION(SPOOLSS_OPNUM_DeletePrinter)
160struct spoolss_DeletePrinter {
161	IN	DWORD dontcare;
162	OUT	DWORD status;
163};
164
165#define SPOOLSS_ARCHITECTURE_NT_X86	( "Windows NT x86" )
166struct spoolss_Time {
167	WORD year;
168	WORD month;
169	WORD day_of_week;
170	WORD day;
171	WORD hour;
172	WORD minute;
173	WORD second;
174	WORD millisecond;
175};
176
177struct spoolss_GetPrinter0 {
178	DWORD printername;
179	DWORD servername;
180	DWORD cjobs;
181	DWORD total_jobs;
182	DWORD total_bytes;
183	DWORD time0;
184	DWORD time1;
185	DWORD time2;
186	DWORD time3;
187	DWORD global_counter;
188	DWORD total_pages;
189	DWORD version;
190	DWORD ffreebuild;
191	DWORD cspooling;
192	DWORD cmaxspooling;
193	DWORD session_counter;
194	DWORD out_of_paper;
195	DWORD not_ready;
196	DWORD job_error;
197	DWORD num_processors;
198	DWORD type_processor;
199	DWORD high_part_total_bytes;
200	DWORD change_id;
201	DWORD last_error;
202	DWORD status;
203	DWORD enum_network_printers;
204	DWORD c_setprinter;
205	WORD processor_arch;
206	WORD processor_level;
207	DWORD ref;
208	DWORD reserved2;
209	DWORD reserved3;
210};
211
212/* bitmap spoolss_EnumPrinterFlags */
213#define PRINTER_ENUM_DEFAULT ( 0x00000001 )
214#define PRINTER_ENUM_LOCAL ( 0x00000002 )
215#define PRINTER_ENUM_CONNECTIONS ( 0x00000004 )
216#define PRINTER_ENUM_FAVORITE ( 0x00000004 )
217#define PRINTER_ENUM_NAME ( 0x00000008 )
218#define PRINTER_ENUM_REMOTE ( 0x00000010 )
219#define PRINTER_ENUM_SHARED ( 0x00000020 )
220#define PRINTER_ENUM_NETWORK ( 0x00000040 )
221#define PRINTER_ENUM_EXPAND ( 0x00004000 )
222#define PRINTER_ENUM_CONTAINER ( 0x00008000 )
223#define PRINTER_ENUM_ICON1 ( 0x00010000 )
224#define PRINTER_ENUM_ICON2 ( 0x00020000 )
225#define PRINTER_ENUM_ICON3 ( 0x00040000 )
226#define PRINTER_ENUM_ICON4 ( 0x00080000 )
227#define PRINTER_ENUM_ICON5 ( 0x00100000 )
228#define PRINTER_ENUM_ICON6 ( 0x00200000 )
229#define PRINTER_ENUM_ICON7 ( 0x00400000 )
230#define PRINTER_ENUM_ICON8 ( 0x00800000 )
231#define PRINTER_ENUM_HIDE ( 0x01000000 )
232
233struct spoolss_GetPrinter1 {
234	DWORD flags;
235	DWORD name;
236	DWORD description;
237	DWORD comment;
238};
239
240/* bitmap spoolss_PrinterAttributes */
241#define PRINTER_ATTRIBUTE_QUEUED ( 0x00000001 )
242#define PRINTER_ATTRIBUTE_DIRECT ( 0x00000002 )
243#define PRINTER_ATTRIBUTE_DEFAULT ( 0x00000004 )
244#define PRINTER_ATTRIBUTE_SHARED ( 0x00000008 )
245#define PRINTER_ATTRIBUTE_NETWORK ( 0x00000010 )
246#define PRINTER_ATTRIBUTE_HIDDEN ( 0x00000020 )
247#define PRINTER_ATTRIBUTE_LOCAL ( 0x00000040 )
248#define PRINTER_ATTRIBUTE_ENABLE_DEVQ ( 0x00000080 )
249#define PRINTER_ATTRIBUTE_KEEPPRINTEDJOBS ( 0x00000100 )
250#define PRINTER_ATTRIBUTE_DO_COMPLETE_FIRST ( 0x00000200 )
251#define PRINTER_ATTRIBUTE_WORK_OFFLINE ( 0x00000400 )
252#define PRINTER_ATTRIBUTE_ENABLE_BIDI ( 0x00000800 )
253#define PRINTER_ATTRIBUTE_RAW_ONLY ( 0x00001000 )
254#define PRINTER_ATTRIBUTE_PUBLISHED ( 0x00002000 )
255#define PRINTER_ATTRIBUTE_FAX ( 0x00004000 )
256#define PRINTER_ATTRIBUTE_TS ( 0x00008000 )
257
258/* bitmap spoolss_PrinterStatus */
259#define PRINTER_STATUS_PAUSED ( 0x00000001 )
260#define PRINTER_STATUS_ERROR ( 0x00000002 )
261#define PRINTER_STATUS_PENDING_DELETION ( 0x00000004 )
262#define PRINTER_STATUS_PAPER_JAM ( 0x00000008 )
263#define PRINTER_STATUS_PAPER_OUT ( 0x00000010 )
264#define PRINTER_STATUS_MANUAL_FEED ( 0x00000020 )
265#define PRINTER_STATUS_PAPER_PROBLEM ( 0x00000040 )
266#define PRINTER_STATUS_OFFLINE ( 0x00000080 )
267#define PRINTER_STATUS_IO_ACTIVE ( 0x00000100 )
268#define PRINTER_STATUS_BUSY ( 0x00000200 )
269#define PRINTER_STATUS_PRINTING ( 0x00000400 )
270#define PRINTER_STATUS_OUTPUT_BIN_FULL ( 0x00000800 )
271#define PRINTER_STATUS_NOT_AVAILABLE ( 0x00001000 )
272#define PRINTER_STATUS_WAITING ( 0x00002000 )
273#define PRINTER_STATUS_PROCESSING ( 0x00004000 )
274#define PRINTER_STATUS_INITIALIZING ( 0x00008000 )
275#define PRINTER_STATUS_WARMING_UP ( 0x00010000 )
276#define PRINTER_STATUS_TONER_LOW ( 0x00020000 )
277#define PRINTER_STATUS_NO_TONER ( 0x00040000 )
278#define PRINTER_STATUS_PAGE_PUNT ( 0x00080000 )
279#define PRINTER_STATUS_USER_INTERVENTION ( 0x00100000 )
280#define PRINTER_STATUS_OUT_OF_MEMORY ( 0x00200000 )
281#define PRINTER_STATUS_DOOR_OPEN ( 0x00400000 )
282#define PRINTER_STATUS_SERVER_UNKNOWN ( 0x00800000 )
283#define PRINTER_STATUS_POWER_SAVE ( 0x01000000 )
284
285struct spoolss_GetPrinter2 {
286	DWORD servername;
287	DWORD printername;
288	DWORD sharename;
289	DWORD portname;
290	DWORD drivername;
291	DWORD comment;
292	DWORD location;
293	DWORD devmode;
294	DWORD sepfile;
295	DWORD printprocessor;
296	DWORD datatype;
297	DWORD parameters;
298	DWORD secdesc;
299	DWORD attributes;
300	DWORD priority;
301	DWORD defaultpriority;
302	DWORD starttime;
303	DWORD untiltime;
304	DWORD status;
305	DWORD cjobs;
306	DWORD averageppm;
307};
308
309typedef struct spoolss_GetPrinter2 spoolss_GetPrinter2_t;
310
311struct spoolss_GetPrinter3 {
312	DWORD dummy;
313};
314
315struct spoolss_GetPrinter4 {
316	DWORD printername;
317	DWORD servername;
318	DWORD attributes;
319};
320
321struct spoolss_GetPrinter5 {
322	DWORD printername;
323	DWORD portname;
324	DWORD attributes;
325	DWORD device_not_selected_timeout;
326	DWORD transmission_retry_timeout;
327};
328
329struct spoolss_GetPrinter6 {
330	DWORD status;
331};
332
333/* bitmap spoolss_DsPrintAction */
334#define DSPRINT_PUBLISH ( 0x00000001 )
335#define DSPRINT_UPDATE ( 0x00000002 )
336#define DSPRINT_UNPUBLISH ( 0x00000004 )
337#define DSPRINT_REPUBLISH ( 0x00000008 )
338#define DSPRINT_PENDING ( 0x80000000 )
339
340struct spoolss_GetPrinter7 {
341	DWORD guid;
342	DWORD action;
343};
344
345struct spoolss_GetPrinter8 {
346	DWORD flags;
347	DWORD name;
348	DWORD description;
349	DWORD comment;
350};
351
352union spoolss_GetPrinter_result_u {
353	UNION_INFO_ENT(0, spoolss_GetPrinter);
354	UNION_INFO_ENT(1, spoolss_GetPrinter);
355	UNION_INFO_ENT(2, spoolss_GetPrinter);
356	UNION_INFO_ENT(3, spoolss_GetPrinter);
357	UNION_INFO_ENT(4, spoolss_GetPrinter);
358	UNION_INFO_ENT(5, spoolss_GetPrinter);
359	UNION_INFO_ENT(6, spoolss_GetPrinter);
360	UNION_INFO_ENT(7, spoolss_GetPrinter);
361	UNION_INFO_ENT(8, spoolss_GetPrinter);
362	DEFAULT char *nullptr;
363};
364
365struct spoolss_GetPrinter_result {
366	DWORD switch_value;
367	SWITCH(switch_value)
368		union spoolss_GetPrinter_result_u ru;
369};
370
371struct spoolss_RPC_V2_NOTIFY_OPTIONS_TYPE {
372	WORD type;
373	WORD reserved0;
374	DWORD reserved1;
375	DWORD reserved2;
376	DWORD count;
377	SIZE_IS(count)
378		WORD *pFields;
379};
380
381struct spoolss_RPC_V2_NOTIFY_OPTIONS {
382	DWORD version;
383	DWORD reserved;
384	DWORD count;
385	SIZE_IS(count)
386		struct spoolss_RPC_V2_NOTIFY_OPTIONS_TYPE *ptypes;
387};
388
389struct SYSTEMTIME {
390	WORD year;
391	WORD month;
392	WORD dayofweek;
393	WORD day;
394	WORD hour;
395	WORD minute;
396	WORD second;
397	WORD millisecs;
398};
399
400struct SECURITY_CONTAINER {
401	DWORD count;
402	SIZE_IS(count)
403		BYTE *psecurity;
404};
405
406struct SYSTEMTIME_CONTAINER {
407	DWORD count;
408	struct SYSTEMTIME *psystemtime;
409};
410
411struct STRING_CONTAINER {
412	DWORD count;
413	SIZE_IS(count / 2)
414		LPTSTR pstring;
415};
416
417union spoolss_RPC_V2_NOTIFY_INFO_DATA_DATA {
418	CASE(TABLE_STRING)
419		struct STRING_CONTAINER pcont;
420	CASE(TABLE_DWORD)
421		DWORD data[2];
422	CASE(TABLE_TIME)
423		struct SYSTEMTIME_CONTAINER system_time;
424	CASE(TABLE_DEVMODE)
425		struct spoolssDevmodeContainer devmode;
426	CASE(TABLE_SECURITY_DESCRIPTOR)
427		struct SECURITY_CONTAINER security_descriptor;
428};
429
430struct spoolss_RPC_V2_NOTIFY_INFO_DATA {
431	WORD Type;
432	WORD Field;
433	DWORD Reserved;
434	DWORD Id;
435	SWITCH(Reserved & 0x0000FFFF)
436		union spoolss_RPC_V2_NOTIFY_INFO_DATA_DATA data;
437};
438
439struct spoolss_RPC_V2_NOTIFY_INFO {
440	DWORD Version;
441	DWORD Flags;
442	DWORD Count;
443	SIZE_IS(Count)
444		struct spoolss_RPC_V2_NOTIFY_INFO_DATA *aData;
445};
446
447OPERATION(SPOOLSS_OPNUM_GetPrinter)
448struct spoolss_GetPrinter {
449	IN	spoolss_handle_t handle;
450	IN 	DWORD 	switch_value;
451  	IN	DWORD   Buf2;
452	IN	DWORD 	BufCount;
453		SIZE_IS(BufCount)
454  	OUT		BYTE *Buf;
455	OUT	DWORD needed;
456	OUT	DWORD status;
457};
458
459OPERATION(SPOOLSS_OPNUM_GetPrinterData)
460struct spoolss_GetPrinterData {
461	IN	spoolss_handle_t handle;
462	IN	REFERENCE LPTSTR pValueName;
463	OUT	DWORD pType;
464    SIZE_IS(Size)
465   	OUT	REFERENCE LPBYTE Buf;
466	IN	DWORD Size;
467	OUT	DWORD Needed;
468	OUT	DWORD status;
469};
470
471OPERATION(SPOOLSS_OPNUM_GetPrinterDriver)
472struct spoolss_GetPrinterDriver {
473	IN	DWORD dontcare;
474	OUT	DWORD status;
475};
476
477OPERATION(SPOOLSS_OPNUM_DeletePrinterDriver)
478struct spoolss_DeletePrinterDriver {
479	IN	DWORD dontcare;
480	OUT	DWORD status;
481};
482
483struct spoolss_DocInfo {
484	LPTSTR doc_name;
485	LPTSTR printer_name;
486	LPTSTR type;
487};
488typedef struct spoolss_DocInfo spoolss_DocInfo_t;
489
490struct spoolss_DocInfo_Container {
491	DWORD level;
492	DWORD switch_value;
493	spoolss_DocInfo_t *DocInfoContainer;
494};
495typedef struct spoolss_DocInfo_Container spoolss_DocInfo_Container_t;
496
497OPERATION(SPOOLSS_OPNUM_StartDocPrinter)
498struct spoolss_StartDocPrinter {
499	IN	spoolss_handle_t handle;
500	IN	spoolss_DocInfo_Container_t dinfo;
501	OUT	DWORD JobId;
502	OUT	DWORD status;
503};
504
505OPERATION(SPOOLSS_OPNUM_AbortPrinter)
506struct spoolss_AbortPrinter {
507	IN	spoolss_handle_t handle;
508	OUT	DWORD status;
509};
510
511OPERATION(SPOOLSS_OPNUM_EnumPorts)
512struct spoolss_EnumPorts {
513	IN	LPTSTR name;
514	IN	DWORD level;
515	OUT	DWORD needed;
516	OUT	DWORD returned;
517	OUT	DWORD status;
518};
519
520OPERATION(SPOOLSS_OPNUM_DeletePort)
521struct spoolss_DeletePort {
522	IN	LPTSTR name;
523	OUT	DWORD status;
524};
525
526OPERATION(SPOOLSS_OPNUM_AddPortEx)
527struct spoolss_AddPortEx {
528	IN	LPTSTR name;
529	OUT	DWORD status;
530};
531
532OPERATION(SPOOLSS_OPNUM_SetPort)
533struct spoolss_SetPort {
534	IN	LPTSTR name;
535	OUT	DWORD status;
536};
537
538OPERATION(SPOOLSS_OPNUM_EnumMonitor)
539struct spoolss_EnumMonitor {
540	IN	LPTSTR name;
541	IN	DWORD level;
542	OUT	DWORD needed;
543	OUT	DWORD returned;
544	OUT	DWORD status;
545};
546
547OPERATION(SPOOLSS_OPNUM_AddMonitor)
548struct spoolss_AddMonitor {
549	IN	LPTSTR name;
550	OUT	DWORD status;
551};
552
553OPERATION(SPOOLSS_OPNUM_DeleteMonitor)
554struct spoolss_DeleteMonitor {
555	IN	LPTSTR name;
556	OUT	DWORD status;
557};
558
559OPERATION(SPOOLSS_OPNUM_ResetPrinter)
560struct spoolss_ResetPrinter {
561	IN	spoolss_handle_t handle;
562	OUT	DWORD status;
563};
564
565OPERATION(SPOOLSS_OPNUM_StartPagePrinter)
566struct spoolss_StartPagePrinter {
567	IN	spoolss_handle_t handle;
568	OUT	DWORD status;
569};
570
571OPERATION(SPOOLSS_OPNUM_EndPagePrinter)
572struct spoolss_EndPagePrinter {
573	IN	spoolss_handle_t handle;
574	OUT	DWORD status;
575};
576
577OPERATION(SPOOLSS_OPNUM_WritePrinter)
578struct spoolss_WritePrinter {
579	IN	spoolss_handle_t handle;
580	IN	DWORD BufCount;
581		SIZE_IS(BufCount)
582  	IN	REFERENCE LPBYTE pBuf;
583	OUT	DWORD written;
584	OUT	DWORD status;
585};
586
587OPERATION(SPOOLSS_OPNUM_ScheduleJob)
588struct spoolss_ScheduleJob {
589	IN	spoolss_handle_t handle;
590	IN 	DWORD 	JobId;
591	OUT	DWORD status;
592};
593
594OPERATION(SPOOLSS_OPNUM_GetJob)
595struct spoolss_GetJob {
596	IN	spoolss_handle_t handle;
597	IN 	DWORD 	JobId;
598	IN	DWORD 	level;
599		SIZE_IS(BufCount)
600  	INOUT		BYTE *pJob;
601	IN	DWORD BufCount;
602	OUT	DWORD needed;
603	OUT	DWORD status;
604};
605
606OPERATION(SPOOLSS_OPNUM_AddJob)
607struct spoolss_AddJob {
608	IN	spoolss_handle_t handle;
609	IN 	DWORD 	level;
610  	IN	DWORD   Buf2;
611	IN	DWORD 	BufCount;
612		SIZE_IS(BufCount)
613  	OUT		BYTE *pAddJob;
614	OUT	DWORD needed;
615	OUT	DWORD status;
616};
617
618OPERATION(SPOOLSS_OPNUM_ClosePrinter)
619struct spoolss_ClosePrinter {
620	IN	spoolss_handle_t handle;
621	OUT	spoolss_handle_t result_handle;
622	OUT	DWORD status;
623};
624
625OPERATION(SPOOLSS_OPNUM_EndDocPrinter)
626struct spoolss_EndDocPrinter {
627	IN	spoolss_handle_t handle;
628	OUT	DWORD status;
629};
630
631OPERATION(SPOOLSS_OPNUM_AddForm)
632struct spoolss_AddForm {
633	IN	spoolss_handle_t handle;
634	/*	FORM_CONTAINER *form_container; */
635	OUT	DWORD status;
636};
637
638OPERATION(SPOOLSS_OPNUM_DeleteForm)
639struct spoolss_DeleteForm {
640	IN	spoolss_handle_t handle;
641	/* IN	REFERENCE LPTSTR form_name; */
642	OUT	DWORD status;
643};
644
645OPERATION(SPOOLSS_OPNUM_EnumForms)
646struct spoolss_EnumForms {
647	IN	spoolss_handle_t handle;
648	IN 	DWORD 	level;
649	IN	DWORD 	BufCount;
650		SIZE_IS(BufCount)
651  	INOUT		BYTE *pEnumForms;
652	OUT	DWORD needed;
653	OUT	DWORD pcRet;
654	OUT	DWORD status;
655};
656
657OPERATION(SPOOLSS_OPNUM_GetPrinterDriver2)
658struct spoolss_GetPrinterDriver2 {
659	IN	DWORD dontcare;
660	OUT	DWORD status;
661};
662
663OPERATION(SPOOLSS_OPNUM_FCPN)
664struct spoolss_FCPN {
665	IN	DWORD dontcare;
666	OUT	DWORD status;
667};
668
669OPERATION(SPOOLSS_OPNUM_ReplyOpenPrinter)
670struct spoolss_ReplyOpenPrinter {
671	IN	DWORD dontcare;
672	OUT	DWORD status;
673};
674
675OPERATION(SPOOLSS_OPNUM_ReplyClosePrinter)
676struct spoolss_ReplyClosePrinter {
677	IN	DWORD dontcare;
678	OUT	DWORD status;
679};
680
681
682OPERATION(SPOOLSS_OPNUM_RFFPCNEX)
683struct spoolss_RFFPCNEX {
684	IN	spoolss_handle_t handle;
685	OUT	DWORD status;
686};
687
688struct spoolss_infores {
689	DWORD entriesread;
690	struct spoolss_RPC_V2_NOTIFY_INFO *pinfo;
691};
692
693OPERATION(SPOOLSS_OPNUM_RFNPCNEX)
694struct spoolss_RFNPCNEX {
695	IN	spoolss_handle_t handle;
696	IN 	DWORD color;
697	IN	struct spoolss_RPC_V2_NOTIFY_OPTIONS *poptions;
698	OUT	struct spoolss_infores *ppinfo;
699	OUT	DWORD status;
700};
701
702OPERATION(SPOOLSS_OPNUM_RRPCN)
703struct spoolss_RRPCN {
704	IN	DWORD dontcare;
705	OUT	DWORD status;
706};
707
708OPERATION(SPOOLSS_OPNUM_OpenPrinterEx)
709struct spoolss_OpenPrinterEx {
710	IN	LPTSTR printer_name;
711	OUT	spoolss_handle_t handle;
712	IN	LPTSTR data_type;
713	/* IN	struct spoolssDevmodeContainer dmodeContainer; */
714	/* IN	DWORD AccessRequired; */
715	/* IN	CLIENT_CONTAINER client_info; */
716	OUT	DWORD status;
717};
718
719OPERATION(SPOOLSS_OPNUM_EnumPrinterData)
720struct spoolss_EnumPrinterData {
721	IN	DWORD dontcare;
722	OUT	DWORD status;
723};
724
725OPERATION(SPOOLSS_OPNUM_EnumPrinterDataEx)
726struct spoolss_EnumPrinterDataEx {
727	IN	DWORD dontcare;
728	OUT	DWORD status;
729};
730
731OPERATION(SPOOLSS_OPNUM_EnumPrinterKey)
732struct spoolss_EnumPrinterKey {
733	IN	DWORD dontcare;
734	OUT	DWORD status;
735};
736
737/*
738 ***********************************************************************
739 * The spoolss interface definition.
740 ***********************************************************************
741 */
742
743INTERFACE(0)
744union spoolss_interface {
745 	CASE(SPOOLSS_OPNUM_OpenPrinter)
746		struct spoolss_OpenPrinter OpenPrinter;
747
748	CASE(SPOOLSS_OPNUM_DeletePrinter)
749		struct spoolss_DeletePrinter DeletePrinter;
750
751	CASE(SPOOLSS_OPNUM_GetPrinter)
752		struct spoolss_GetPrinter GetPrinter;
753
754	CASE(SPOOLSS_OPNUM_GetPrinterData)
755		struct spoolss_GetPrinterData GetPrinterData;
756
757	CASE(SPOOLSS_OPNUM_AbortPrinter)
758		struct spoolss_AbortPrinter AbortPrinter;
759
760	CASE(SPOOLSS_OPNUM_StartDocPrinter)
761		struct spoolss_StartDocPrinter StartDocPrinter;
762
763	CASE(SPOOLSS_OPNUM_EndDocPrinter)
764		struct spoolss_EndDocPrinter EndDocPrinter;
765
766	CASE(SPOOLSS_OPNUM_CreatePrinterIC)
767		struct spoolss_CreatePrinterIC CreatePrinterIC;
768
769	CASE(SPOOLSS_OPNUM_ResetPrinter)
770		struct spoolss_ResetPrinter ResetPrinter;
771
772	CASE(SPOOLSS_OPNUM_EnumMonitor)
773		struct spoolss_EnumMonitor EnumMonitor;
774
775	CASE(SPOOLSS_OPNUM_AddMonitor)
776		struct spoolss_AddMonitor AddMonitor;
777
778	CASE(SPOOLSS_OPNUM_DeleteMonitor)
779		struct spoolss_DeleteMonitor DeleteMonitor;
780
781	CASE(SPOOLSS_OPNUM_WritePrinter)
782		struct spoolss_WritePrinter WritePrinter;
783
784	CASE(SPOOLSS_OPNUM_StartPagePrinter)
785		struct spoolss_StartPagePrinter StartPagePrinter;
786
787	CASE(SPOOLSS_OPNUM_EndPagePrinter)
788		struct spoolss_EndPagePrinter EndPagePrinter;
789
790	CASE(SPOOLSS_OPNUM_ClosePrinter)
791		struct spoolss_ClosePrinter ClosePrinter;
792
793	CASE(SPOOLSS_OPNUM_OpenPrinterEx)
794		struct spoolss_OpenPrinterEx OpenPrinterEx;
795
796	CASE(SPOOLSS_OPNUM_AddJob)
797		struct spoolss_AddJob AddJob;
798
799	CASE(SPOOLSS_OPNUM_GetJob)
800		struct spoolss_GetJob GetJob;
801
802	CASE(SPOOLSS_OPNUM_ScheduleJob)
803		struct spoolss_ScheduleJob ScheduleJob;
804
805	CASE(SPOOLSS_OPNUM_AddForm)
806		struct spoolss_AddForm AddForm;
807
808	CASE(SPOOLSS_OPNUM_DeleteForm)
809		struct spoolss_DeleteForm DeleteForm;
810
811	CASE(SPOOLSS_OPNUM_EnumForms)
812		struct spoolss_EnumForms EnumForms;
813
814	CASE(SPOOLSS_OPNUM_EnumPorts)
815		struct spoolss_EnumPorts EnumPorts;
816
817	CASE(SPOOLSS_OPNUM_DeletePort)
818		struct spoolss_DeletePort DeletePort;
819
820	CASE(SPOOLSS_OPNUM_AddPortEx)
821		struct spoolss_AddPortEx AddPortEx;
822
823	CASE(SPOOLSS_OPNUM_SetPort)
824		struct spoolss_SetPort SetPort;
825
826	CASE(SPOOLSS_OPNUM_RFNPCNEX)
827		struct spoolss_RFNPCNEX RFNPCNEX;
828
829};
830typedef union spoolss_interface	spoolss_interface_t;
831EXTERNTYPEINFO(spoolss_interface)
832
833#endif /* _SPOOLSS_NDL_ */
834