preparing for release of alpha.0.10
[Samba.git] / source / include / rpc_spoolss.h
blob69820676cc00d19dcc926d3ed929360fe831c235
1 /*
2 Unix SMB/Netbios implementation.
3 Version 1.9.
4 SMB parameters and setup
5 Copyright (C) Andrew Tridgell 1992-2000,
6 Copyright (C) Luke Kenneth Casson Leighton 1996-2000,
7 Copyright (C) Jean Francois Micouleau 1998-2000.
9 This program is free software; you can redistribute it and/or modify
10 it under the terms of the GNU General Public License as published by
11 the Free Software Foundation; either version 2 of the License, or
12 (at your option) any later version.
14 This program is distributed in the hope that it will be useful,
15 but WITHOUT ANY WARRANTY; without even the implied warranty of
16 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 GNU General Public License for more details.
19 You should have received a copy of the GNU General Public License
20 along with this program; if not, write to the Free Software
21 Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
24 #ifndef _RPC_SPOOLSS_H /* _RPC_SPOOLSS_H */
25 #define _RPC_SPOOLSS_H
27 #define INTEGER 1
28 #define STRING 2
30 /* spoolss pipe: this are the calls which are not implemented ...
31 #define SPOOLSS_OPENPRINTER 0x01
32 #define SPOOLSS_DELETEPRINTER 0x06
33 #define SPOOLSS_GETPRINTERDRIVER 0x0b
34 #define SPOOLSS_DELETEPRINTERDRIVER 0x0d
35 #define SPOOLSS_ADDPRINTPROCESSOR 0x0e
36 #define SPOOLSS_GETPRINTPROCESSORDIRECTORY 0x10
37 #define SPOOLSS_ABORTPRINTER 0x15
38 #define SPOOLSS_READPRINTER 0x16
39 #define SPOOLSS_WAITFORPRINTERCHANGE 0x1c
40 #define SPOOLSS_DELETEFORM 0x1f
41 #define SPOOLSS_GETFORM 0x20
42 #define SPOOLSS_ADDPORT 0x25
43 #define SPOOLSS_CONFIGUREPORT 0x26
44 #define SPOOLSS_DELETEPORT 0x27
45 #define SPOOLSS_CREATEPRINTERIC 0x28
46 #define SPOOLSS_PLAYGDISCRIPTONPRINTERIC 0x29
47 #define SPOOLSS_DELETEPRINTERIC 0x2a
48 #define SPOOLSS_ADDPRINTERCONNECTION 0x2b
49 #define SPOOLSS_DELETEPRINTERCONNECTION 0x2c
50 #define SPOOLSS_PRINTERMESSAGEBOX 0x2d
51 #define SPOOLSS_ADDMONITOR 0x2e
52 #define SPOOLSS_DELETEMONITOR 0x2f
53 #define SPOOLSS_DELETEPRINTPROCESSOR 0x30
54 #define SPOOLSS_ADDPRINTPROVIDOR 0x31
55 #define SPOOLSS_DELETEPRINTPROVIDOR 0x32
56 #define SPOOLSS_RESETPRINTER 0x34
57 #define SPOOLSS_FINDFIRSTPRINTERCHANGENOTIFICATION 0x36
58 #define SPOOLSS_FINDNEXTPRINTERCHANGENOTIFICATION 0x37
59 #define SPOOLSS_ROUTERFINDFIRSTPRINTERNOTIFICATIONOLD 0x39
60 #define SPOOLSS_REPLYOPENPRINTER 0x3a
61 #define SPOOLSS_ROUTERREPLYPRINTER 0x3b
62 #define SPOOLSS_REPLYCLOSEPRINTER 0x3c
63 #define SPOOLSS_ADDPORTEX 0x3d
64 #define SPOOLSS_REMOTEFINDFIRSTPRINTERCHANGENOTIFICATION0x3e
65 #define SPOOLSS_SPOOLERINIT 0x3f
66 #define SPOOLSS_RESETPRINTEREX 0x40
67 #define SPOOLSS_ROUTERREFRESHPRINTERCHANGENOTIFICATION 0x42
70 /* those are implemented */
71 #define SPOOLSS_ENUMPRINTERS 0x00
72 #define SPOOLSS_SETJOB 0x02
73 #define SPOOLSS_GETJOB 0x03
74 #define SPOOLSS_ENUMJOBS 0x04
75 #define SPOOLSS_ADDPRINTER 0x05
76 #define SPOOLSS_SETPRINTER 0x07
77 #define SPOOLSS_GETPRINTER 0x08
78 #define SPOOLSS_ADDPRINTERDRIVER 0x09
79 #define SPOOLSS_ENUMPRINTERDRIVERS 0x0a
80 #define SPOOLSS_GETPRINTERDRIVERDIRECTORY 0x0c
81 #define SPOOLSS_ENUMPRINTPROCESSORS 0x0f
82 #define SPOOLSS_STARTDOCPRINTER 0x11
83 #define SPOOLSS_STARTPAGEPRINTER 0x12
84 #define SPOOLSS_WRITEPRINTER 0x13
85 #define SPOOLSS_ENDPAGEPRINTER 0x14
86 #define SPOOLSS_ENDDOCPRINTER 0x17
87 #define SPOOLSS_ADDJOB 0x18
88 #define SPOOLSS_SCHEDULEJOB 0x19
89 #define SPOOLSS_GETPRINTERDATA 0x1a
90 #define SPOOLSS_SETPRINTERDATA 0x1b
91 #define SPOOLSS_CLOSEPRINTER 0x1d
92 #define SPOOLSS_ADDFORM 0x1e
93 #define SPOOLSS_SETFORM 0x21
94 #define SPOOLSS_ENUMFORMS 0x22
95 #define SPOOLSS_ENUMPORTS 0x23
96 #define SPOOLSS_ENUMMONITORS 0x24
97 #define SPOOLSS_ENUMPRINTPROCDATATYPES 0x33
98 #define SPOOLSS_GETPRINTERDRIVER2 0x35
99 /* find close printer notification */
100 #define SPOOLSS_FCPN 0x38
101 /* remote find first printer change notifyEx */
102 #define SPOOLSS_RFFPCNEX 0x41
103 /* remote find next printer change notifyEx */
104 #define SPOOLSS_RFNPCNEX 0x43
105 #define SPOOLSS_OPENPRINTEREX 0x45
106 #define SPOOLSS_ADDPRINTEREX 0x46
107 #define SPOOLSS_ENUMPRINTERDATA 0x48
109 #define PRINTER_CONTROL_UNPAUSE 0x00000000
110 #define PRINTER_CONTROL_PAUSE 0x00000001
111 #define PRINTER_CONTROL_RESUME 0x00000002
112 #define PRINTER_CONTROL_PURGE 0x00000003
113 #define PRINTER_CONTROL_SET_STATUS 0x00000004
115 #define PRINTER_STATUS_PAUSED 0x00000001
116 #define PRINTER_STATUS_ERROR 0x00000002
117 #define PRINTER_STATUS_PENDING_DELETION 0x00000004
118 #define PRINTER_STATUS_PAPER_JAM 0x00000008
120 #define PRINTER_STATUS_PAPER_OUT 0x00000010
121 #define PRINTER_STATUS_MANUAL_FEED 0x00000020
122 #define PRINTER_STATUS_PAPER_PROBLEM 0x00000040
123 #define PRINTER_STATUS_OFFLINE 0x00000080
125 #define PRINTER_STATUS_IO_ACTIVE 0x00000100
126 #define PRINTER_STATUS_BUSY 0x00000200
127 #define PRINTER_STATUS_PRINTING 0x00000400
128 #define PRINTER_STATUS_OUTPUT_BIN_FULL 0x00000800
130 #define PRINTER_STATUS_NOT_AVAILABLE 0x00001000
131 #define PRINTER_STATUS_WAITING 0x00002000
132 #define PRINTER_STATUS_PROCESSING 0x00004000
133 #define PRINTER_STATUS_INITIALIZING 0x00008000
135 #define PRINTER_STATUS_WARMING_UP 0x00010000
136 #define PRINTER_STATUS_TONER_LOW 0x00020000
137 #define PRINTER_STATUS_NO_TONER 0x00040000
138 #define PRINTER_STATUS_PAGE_PUNT 0x00080000
140 #define PRINTER_STATUS_USER_INTERVENTION 0x00100000
141 #define PRINTER_STATUS_OUT_OF_MEMORY 0x00200000
142 #define PRINTER_STATUS_DOOR_OPEN 0x00400000
143 #define PRINTER_STATUS_SERVER_UNKNOWN 0x00800000
145 #define PRINTER_STATUS_POWER_SAVE 0x01000000
148 #define SERVER_ACCESS_ADMINISTER 0x00000001
149 #define SERVER_ACCESS_ENUMERATE 0x00000002
150 #define PRINTER_ACCESS_ADMINISTER 0x00000004
151 #define PRINTER_ACCESS_USE 0x00000008
152 #define JOB_ACCESS_ADMINISTER 0x00000010
154 #define STANDARD_RIGHTS_READ 0x00020000
155 #define STANDARD_RIGHTS_WRITE STANDARD_RIGHTS_READ
156 #define STANDARD_RIGHTS_EXECUTE STANDARD_RIGHTS_READ
157 #define STANDARD_RIGHTS_REQUIRED 0x000F0000
159 /* Access rights for print servers */
160 #define SERVER_ALL_ACCESS STANDARD_RIGHTS_REQUIRED|SERVER_ACCESS_ADMINISTER|SERVER_ACCESS_ENUMERATE
161 #define SERVER_READ STANDARD_RIGHTS_READ|SERVER_ACCESS_ENUMERATE
162 #define SERVER_WRITE STANDARD_RIGHTS_WRITE|SERVER_ACCESS_ADMINISTER|SERVER_ACCESS_ENUMERATE
163 #define SERVER_EXECUTE STANDARD_RIGHTS_EXECUTE|SERVER_ACCESS_ENUMERATE
165 /* Access rights for printers */
166 #define PRINTER_ALL_ACCESS STANDARD_RIGHTS_REQUIRED|PRINTER_ACCESS_ADMINISTER|PRINTER_ACCESS_USE
167 #define PRINTER_READ STANDARD_RIGHTS_READ|PRINTER_ACCESS_USE
168 #define PRINTER_WRITE STANDARD_RIGHTS_WRITE|PRINTER_ACCESS_USE
169 #define PRINTER_EXECUTE STANDARD_RIGHTS_EXECUTE|PRINTER_ACCESS_USE
171 /* Access rights for jobs */
172 #define JOB_ALL_ACCESS STANDARD_RIGHTS_REQUIRED|JOB_ACCESS_ADMINISTER
173 #define JOB_READ STANDARD_RIGHTS_READ|JOB_ACCESS_ADMINISTER
174 #define JOB_WRITE STANDARD_RIGHTS_WRITE|JOB_ACCESS_ADMINISTER
175 #define JOB_EXECUTE STANDARD_RIGHTS_EXECUTE|JOB_ACCESS_ADMINISTER
177 #define POLICY_HND_SIZE 20
179 #define ONE_VALUE 01
180 #define TWO_VALUE 02
181 #define POINTER 03
183 #define PRINTER_NOTIFY_TYPE 0x00
184 #define JOB_NOTIFY_TYPE 0x01
186 #define MAX_PRINTER_NOTIFY 26
187 #define MAX_JOB_NOTIFY 24
189 #define MAX_NOTIFY_TYPE_FOR_NOW 26
191 #define PRINTER_NOTIFY_SERVER_NAME 0x00
192 #define PRINTER_NOTIFY_PRINTER_NAME 0x01
193 #define PRINTER_NOTIFY_SHARE_NAME 0x02
194 #define PRINTER_NOTIFY_PORT_NAME 0x03
195 #define PRINTER_NOTIFY_DRIVER_NAME 0x04
196 #define PRINTER_NOTIFY_COMMENT 0x05
197 #define PRINTER_NOTIFY_LOCATION 0x06
198 #define PRINTER_NOTIFY_DEVMODE 0x07
199 #define PRINTER_NOTIFY_SEPFILE 0x08
200 #define PRINTER_NOTIFY_PRINT_PROCESSOR 0x09
201 #define PRINTER_NOTIFY_PARAMETERS 0x0A
202 #define PRINTER_NOTIFY_DATATYPE 0x0B
203 #define PRINTER_NOTIFY_SECURITY_DESCRIPTOR 0x0C
204 #define PRINTER_NOTIFY_ATTRIBUTES 0x0D
205 #define PRINTER_NOTIFY_PRIORITY 0x0E
206 #define PRINTER_NOTIFY_DEFAULT_PRIORITY 0x0F
207 #define PRINTER_NOTIFY_START_TIME 0x10
208 #define PRINTER_NOTIFY_UNTIL_TIME 0x11
209 #define PRINTER_NOTIFY_STATUS 0x12
210 #define PRINTER_NOTIFY_STATUS_STRING 0x13
211 #define PRINTER_NOTIFY_CJOBS 0x14
212 #define PRINTER_NOTIFY_AVERAGE_PPM 0x15
213 #define PRINTER_NOTIFY_TOTAL_PAGES 0x16
214 #define PRINTER_NOTIFY_PAGES_PRINTED 0x17
215 #define PRINTER_NOTIFY_TOTAL_BYTES 0x18
216 #define PRINTER_NOTIFY_BYTES_PRINTED 0x19
218 #define JOB_NOTIFY_PRINTER_NAME 0x00
219 #define JOB_NOTIFY_MACHINE_NAME 0x01
220 #define JOB_NOTIFY_PORT_NAME 0x02
221 #define JOB_NOTIFY_USER_NAME 0x03
222 #define JOB_NOTIFY_NOTIFY_NAME 0x04
223 #define JOB_NOTIFY_DATATYPE 0x05
224 #define JOB_NOTIFY_PRINT_PROCESSOR 0x06
225 #define JOB_NOTIFY_PARAMETERS 0x07
226 #define JOB_NOTIFY_DRIVER_NAME 0x08
227 #define JOB_NOTIFY_DEVMODE 0x09
228 #define JOB_NOTIFY_STATUS 0x0A
229 #define JOB_NOTIFY_STATUS_STRING 0x0B
230 #define JOB_NOTIFY_SECURITY_DESCRIPTOR 0x0C
231 #define JOB_NOTIFY_DOCUMENT 0x0D
232 #define JOB_NOTIFY_PRIORITY 0x0E
233 #define JOB_NOTIFY_POSITION 0x0F
234 #define JOB_NOTIFY_SUBMITTED 0x10
235 #define JOB_NOTIFY_START_TIME 0x11
236 #define JOB_NOTIFY_UNTIL_TIME 0x12
237 #define JOB_NOTIFY_TIME 0x13
238 #define JOB_NOTIFY_TOTAL_PAGES 0x14
239 #define JOB_NOTIFY_PAGES_PRINTED 0x15
240 #define JOB_NOTIFY_TOTAL_BYTES 0x16
241 #define JOB_NOTIFY_BYTES_PRINTED 0x17
243 #define PRINTER_CHANGE_ADD_PRINTER 0x00000001
244 #define PRINTER_CHANGE_SET_PRINTER 0x00000002
245 #define PRINTER_CHANGE_DELETE_PRINTER 0x00000004
246 #define PRINTER_CHANGE_FAILED_CONNECTION_PRINTER 0x00000008
247 #define PRINTER_CHANGE_PRINTER (PRINTER_CHANGE_ADD_PRINTER | \
248 PRINTER_CHANGE_SET_PRINTER | \
249 PRINTER_CHANGE_DELETE_PRINTER | \
250 PRINTER_CHANGE_FAILED_CONNECTION_PRINTER )
252 #define PRINTER_CHANGE_ADD_JOB 0x00000100
253 #define PRINTER_CHANGE_SET_JOB 0x00000200
254 #define PRINTER_CHANGE_DELETE_JOB 0x00000400
255 #define PRINTER_CHANGE_WRITE_JOB 0x00000800
256 #define PRINTER_CHANGE_JOB (PRINTER_CHANGE_ADD_JOB | \
257 PRINTER_CHANGE_SET_JOB | \
258 PRINTER_CHANGE_DELETE_JOB | \
259 PRINTER_CHANGE_WRITE_JOB )
261 #define PRINTER_CHANGE_ADD_FORM 0x00010000
262 #define PRINTER_CHANGE_SET_FORM 0x00020000
263 #define PRINTER_CHANGE_DELETE_FORM 0x00040000
264 #define PRINTER_CHANGE_FORM (PRINTER_CHANGE_ADD_FORM | \
265 PRINTER_CHANGE_SET_FORM | \
266 PRINTER_CHANGE_DELETE_FORM )
268 #define PRINTER_CHANGE_ADD_PORT 0x00100000
269 #define PRINTER_CHANGE_CONFIGURE_PORT 0x00200000
270 #define PRINTER_CHANGE_DELETE_PORT 0x00400000
271 #define PRINTER_CHANGE_PORT (PRINTER_CHANGE_ADD_PORT | \
272 PRINTER_CHANGE_CONFIGURE_PORT | \
273 PRINTER_CHANGE_DELETE_PORT )
275 #define PRINTER_CHANGE_ADD_PRINT_PROCESSOR 0x01000000
276 #define PRINTER_CHANGE_DELETE_PRINT_PROCESSOR 0x04000000
277 #define PRINTER_CHANGE_PRINT_PROCESSOR (PRINTER_CHANGE_ADD_PRINT_PROCESSOR | \
278 PRINTER_CHANGE_DELETE_PRINT_PROCESSOR )
280 #define PRINTER_CHANGE_ADD_PRINTER_DRIVER 0x10000000
281 #define PRINTER_CHANGE_SET_PRINTER_DRIVER 0x20000000
282 #define PRINTER_CHANGE_DELETE_PRINTER_DRIVER 0x40000000
283 #define PRINTER_CHANGE_PRINTER_DRIVER (PRINTER_CHANGE_ADD_PRINTER_DRIVER | \
284 PRINTER_CHANGE_SET_PRINTER_DRIVER | \
285 PRINTER_CHANGE_DELETE_PRINTER_DRIVER )
287 #define PRINTER_CHANGE_TIMEOUT 0x80000000
288 #define PRINTER_CHANGE_ALL (PRINTER_CHANGE_JOB | \
289 PRINTER_CHANGE_FORM | \
290 PRINTER_CHANGE_PORT | \
291 PRINTER_CHANGE_PRINT_PROCESSOR | \
292 PRINTER_CHANGE_PRINTER_DRIVER )
295 * The printer attributes.
296 * I #defined all of them (grabbed form MSDN)
297 * I'm only using:
298 * ( SHARED | NETWORK | RAW_ONLY )
299 * RAW_ONLY _MUST_ be present otherwise NT will send an EMF file
302 #define PRINTER_ATTRIBUTE_QUEUED 0x00000001
303 #define PRINTER_ATTRIBUTE_DIRECT 0x00000002
304 #define PRINTER_ATTRIBUTE_DEFAULT 0x00000004
305 #define PRINTER_ATTRIBUTE_SHARED 0x00000008
307 #define PRINTER_ATTRIBUTE_NETWORK 0x00000010
308 #define PRINTER_ATTRIBUTE_HIDDEN 0x00000020
309 #define PRINTER_ATTRIBUTE_LOCAL 0x00000040
310 #define PRINTER_ATTRIBUTE_ENABLE_DEVQ 0x00000080
312 #define PRINTER_ATTRIBUTE_KEEPPRINTEDJOBS 0x00000100
313 #define PRINTER_ATTRIBUTE_DO_COMPLETE_FIRST 0x00000200
314 #define PRINTER_ATTRIBUTE_WORK_OFFLINE 0x00000400
315 #define PRINTER_ATTRIBUTE_ENABLE_BIDI 0x00000800
317 #define PRINTER_ATTRIBUTE_RAW_ONLY 0x00001000
319 #define NO_PRIORITY 0
320 #define MAX_PRIORITY 99
321 #define MIN_PRIORITY 1
322 #define DEF_PRIORITY 1
324 /* the flags of the query */
325 #define PRINTER_ENUM_DEFAULT 0x00000001
326 #define PRINTER_ENUM_LOCAL 0x00000002
327 #define PRINTER_ENUM_CONNECTIONS 0x00000004
328 #define PRINTER_ENUM_FAVORITE 0x00000004
329 #define PRINTER_ENUM_NAME 0x00000008
330 #define PRINTER_ENUM_REMOTE 0x00000010
331 #define PRINTER_ENUM_SHARED 0x00000020
332 #define PRINTER_ENUM_NETWORK 0x00000040
334 /* the flags of each printers */
335 #define PRINTER_ENUM_EXPAND 0x00004000
336 #define PRINTER_ENUM_CONTAINER 0x00008000
337 #define PRINTER_ENUM_ICONMASK 0x00ff0000
338 #define PRINTER_ENUM_ICON1 0x00010000
339 #define PRINTER_ENUM_ICON2 0x00020000
340 #define PRINTER_ENUM_ICON3 0x00040000
341 #define PRINTER_ENUM_ICON4 0x00080000
342 #define PRINTER_ENUM_ICON5 0x00100000
343 #define PRINTER_ENUM_ICON6 0x00200000
344 #define PRINTER_ENUM_ICON7 0x00400000
345 #define PRINTER_ENUM_ICON8 0x00800000
347 #define POLICY_HND_SIZE 20
349 /* this struct is undocumented */
350 /* thanks to the ddk ... */
351 typedef struct spool_user_1
353 uint32 size;
354 uint32 client_name_ptr;
355 uint32 user_name_ptr;
356 uint32 build;
357 uint32 major;
358 uint32 minor;
359 uint32 processor;
360 UNISTR2 client_name;
361 UNISTR2 user_name;
362 } SPOOL_USER_1;
364 typedef struct spool_user_ctr_info
366 uint32 level;
367 uint32 ptr;
368 SPOOL_USER_1 user1;
369 } SPOOL_USER_CTR;
371 typedef struct devicemode
373 UNISTR devicename;
374 uint16 specversion;
375 uint16 driverversion;
376 uint16 size;
377 uint16 driverextra;
378 uint32 fields;
379 uint16 orientation;
380 uint16 papersize;
381 uint16 paperlength;
382 uint16 paperwidth;
383 uint16 scale;
384 uint16 copies;
385 uint16 defaultsource;
386 uint16 printquality;
387 uint16 color;
388 uint16 duplex;
389 uint16 yresolution;
390 uint16 ttoption;
391 uint16 collate;
392 UNISTR formname;
393 uint16 logpixels;
394 uint32 bitsperpel;
395 uint32 pelswidth;
396 uint32 pelsheight;
397 uint32 displayflags;
398 uint32 displayfrequency;
399 uint32 icmmethod;
400 uint32 icmintent;
401 uint32 mediatype;
402 uint32 dithertype;
403 uint32 reserved1;
404 uint32 reserved2;
405 uint32 panningwidth;
406 uint32 panningheight;
407 uint8 *private;
408 } DEVICEMODE;
410 typedef struct _devmode_cont
412 uint32 size;
413 uint32 devmode_ptr;
414 DEVICEMODE *devmode;
415 } DEVMODE_CTR;
417 typedef struct _printer_default
419 uint32 datatype_ptr;
420 UNISTR2 datatype;
421 DEVMODE_CTR devmode_cont;
422 uint32 access_required;
423 } PRINTER_DEFAULT;
425 /* SPOOL_Q_OPEN_PRINTER_EX request to open a printer */
426 typedef struct spool_q_open_printer_ex
428 uint32 printername_ptr;
429 UNISTR2 printername;
430 PRINTER_DEFAULT printer_default;
431 uint32 user_switch;
432 SPOOL_USER_CTR user_ctr;
433 } SPOOL_Q_OPEN_PRINTER_EX;
435 /* SPOOL_R_OPEN_PRINTER_EX reply to an open printer */
436 typedef struct spool_r_open_printer_ex
438 POLICY_HND handle; /* handle used along all transactions (20*uint8) */
439 uint32 status;
441 } SPOOL_R_OPEN_PRINTER_EX;
443 typedef struct spool_notify_option_type
445 uint16 type;
446 uint16 reserved0;
447 uint32 reserved1;
448 uint32 reserved2;
449 uint32 count;
450 uint32 fields_ptr;
451 uint32 count2;
452 uint16 fields[MAX_NOTIFY_TYPE_FOR_NOW];
453 } SPOOL_NOTIFY_OPTION_TYPE;
455 typedef struct spool_notify_option_type_ctr
457 uint32 count;
458 SPOOL_NOTIFY_OPTION_TYPE *type;
459 } SPOOL_NOTIFY_OPTION_TYPE_CTR;
463 typedef struct s_header_type
465 uint32 type;
466 union
468 uint32 value;
469 UNISTR string;
470 } data;
471 } HEADER_TYPE;
473 typedef struct new_buffer
475 uint32 ptr;
476 uint32 size;
477 prs_struct prs;
478 uint32 struct_start;
479 uint32 string_at_end;
480 } NEW_BUFFER;
482 typedef struct spool_q_getprinterdata
484 POLICY_HND handle;
485 UNISTR2 valuename;
486 uint32 size;
487 } SPOOL_Q_GETPRINTERDATA;
489 typedef struct spool_r_getprinterdata
491 uint32 type;
492 uint32 size;
493 uint8 *data;
494 uint32 needed;
495 uint32 status;
496 } SPOOL_R_GETPRINTERDATA;
498 typedef struct spool_q_closeprinter
500 POLICY_HND handle;
501 } SPOOL_Q_CLOSEPRINTER;
503 typedef struct spool_r_closeprinter
505 POLICY_HND handle;
506 uint32 status;
507 } SPOOL_R_CLOSEPRINTER;
509 typedef struct spool_q_startpageprinter
511 POLICY_HND handle;
512 } SPOOL_Q_STARTPAGEPRINTER;
514 typedef struct spool_r_startpageprinter
516 uint32 status;
517 } SPOOL_R_STARTPAGEPRINTER;
519 typedef struct spool_q_endpageprinter
521 POLICY_HND handle;
522 } SPOOL_Q_ENDPAGEPRINTER;
524 typedef struct spool_r_endpageprinter
526 uint32 status;
527 } SPOOL_R_ENDPAGEPRINTER;
529 typedef struct spool_doc_info_1
531 uint32 p_docname;
532 uint32 p_outputfile;
533 uint32 p_datatype;
534 UNISTR2 docname;
535 UNISTR2 outputfile;
536 UNISTR2 datatype;
537 } DOC_INFO_1;
539 typedef struct spool_doc_info
541 uint32 switch_value;
542 DOC_INFO_1 doc_info_1;
543 } DOC_INFO;
545 typedef struct spool_doc_info_container
547 uint32 level;
548 DOC_INFO docinfo;
549 } DOC_INFO_CONTAINER;
551 typedef struct spool_q_startdocprinter
553 POLICY_HND handle;
554 DOC_INFO_CONTAINER doc_info_container;
555 } SPOOL_Q_STARTDOCPRINTER;
557 typedef struct spool_r_startdocprinter
559 uint32 jobid;
560 uint32 status;
561 } SPOOL_R_STARTDOCPRINTER;
563 typedef struct spool_q_enddocprinter
565 POLICY_HND handle;
566 } SPOOL_Q_ENDDOCPRINTER;
568 typedef struct spool_r_enddocprinter
570 uint32 status;
571 } SPOOL_R_ENDDOCPRINTER;
573 typedef struct spool_q_writeprinter
575 POLICY_HND handle;
576 uint32 buffer_size;
577 uint8 *buffer;
578 uint32 buffer_size2;
579 } SPOOL_Q_WRITEPRINTER;
581 typedef struct spool_r_writeprinter
583 uint32 buffer_written;
584 uint32 status;
585 } SPOOL_R_WRITEPRINTER;
587 typedef struct spool_notify_option
589 uint32 version;
590 uint32 flags;
591 uint32 count;
592 uint32 option_type_ptr;
593 SPOOL_NOTIFY_OPTION_TYPE_CTR ctr;
594 } SPOOL_NOTIFY_OPTION;
596 typedef struct spool_notify_info_data
598 uint16 type;
599 uint16 field;
600 uint32 reserved;
601 uint32 id;
602 union
604 uint32 value[2];
605 struct
607 uint32 length;
608 uint16 string[1024];
609 } data;
610 } notify_data;
611 uint32 size;
612 BOOL enc_type;
613 } SPOOL_NOTIFY_INFO_DATA;
615 typedef struct spool_notify_info
617 uint32 version;
618 uint32 flags;
619 uint32 count;
620 SPOOL_NOTIFY_INFO_DATA *data;
621 } SPOOL_NOTIFY_INFO;
623 /* If the struct name looks obscure, yes it is ! */
624 /* RemoteFindFirstPrinterChangeNotificationEx query struct */
625 typedef struct spoolss_q_rffpcnex
627 POLICY_HND handle;
628 uint32 flags;
629 uint32 options;
630 uint32 localmachine_ptr;
631 UNISTR2 localmachine;
632 uint32 printerlocal;
633 uint32 option_ptr;
634 SPOOL_NOTIFY_OPTION *option;
635 } SPOOL_Q_RFFPCNEX;
637 typedef struct spool_r_rffpcnex
639 uint32 status;
640 } SPOOL_R_RFFPCNEX;
642 /* Remote Find Next Printer Change Notify Ex */
643 typedef struct spool_q_rfnpcnex
645 POLICY_HND handle;
646 uint32 change;
647 uint32 option_ptr;
648 SPOOL_NOTIFY_OPTION *option;
649 } SPOOL_Q_RFNPCNEX;
651 typedef struct spool_r_rfnpcnex
653 uint32 info_ptr;
654 SPOOL_NOTIFY_INFO info;
655 uint32 status;
656 } SPOOL_R_RFNPCNEX;
658 /* Find Close Printer Notify */
659 typedef struct spool_q_fcpn
661 POLICY_HND handle;
662 } SPOOL_Q_FCPN;
664 typedef struct spool_r_fcpn
666 uint32 status;
667 } SPOOL_R_FCPN;
670 typedef struct printer_info_0
672 UNISTR printername;
673 UNISTR servername;
674 uint32 cjobs;
675 uint32 attributes;
676 uint32 unknown0;
677 uint32 unknown1;
678 uint32 unknown2;
679 uint32 unknown3;
680 uint32 unknown4;
681 uint32 unknown5;
682 uint32 unknown6;
683 uint16 majorversion;
684 uint16 buildversion;
685 uint32 unknown7;
686 uint32 unknown8;
687 uint32 unknown9;
688 uint32 unknown10;
689 uint32 unknown11;
690 uint32 unknown12;
691 uint32 unknown13;
692 uint32 unknown14;
693 uint32 unknown15;
694 uint32 unknown16;
695 uint32 unknown17;
696 uint32 unknown18;
697 uint32 status;
698 uint32 unknown20;
699 uint32 unknown21;
700 uint16 unknown22;
701 uint32 unknown23;
702 } PRINTER_INFO_0;
704 typedef struct printer_info_1
706 uint32 flags;
707 UNISTR description;
708 UNISTR name;
709 UNISTR comment;
710 } PRINTER_INFO_1;
712 typedef struct printer_info_2
714 UNISTR servername;
715 UNISTR printername;
716 UNISTR sharename;
717 UNISTR portname;
718 UNISTR drivername;
719 UNISTR comment;
720 UNISTR location;
721 DEVICEMODE *devmode;
722 UNISTR sepfile;
723 UNISTR printprocessor;
724 UNISTR datatype;
725 UNISTR parameters;
726 /*SECURITY_DESCRIPTOR securitydescriptor;*/
727 uint32 attributes;
728 uint32 priority;
729 uint32 defaultpriority;
730 uint32 starttime;
731 uint32 untiltime;
732 uint32 status;
733 uint32 cjobs;
734 uint32 averageppm;
735 } PRINTER_INFO_2;
737 typedef struct spool_q_enumprinters
739 uint32 flags;
740 uint32 servername_ptr;
741 UNISTR2 servername;
742 uint32 level;
743 NEW_BUFFER *buffer;
744 uint32 offered;
745 } SPOOL_Q_ENUMPRINTERS;
747 typedef struct printer_info_ctr_info
749 PRINTER_INFO_1 *printers_1;
750 PRINTER_INFO_2 *printers_2;
751 } PRINTER_INFO_CTR;
753 typedef struct spool_r_enumprinters
755 NEW_BUFFER *buffer;
756 uint32 needed; /* bytes needed */
757 uint32 returned; /* number of printers */
758 uint32 status;
759 } SPOOL_R_ENUMPRINTERS;
762 typedef struct spool_q_getprinter
764 POLICY_HND handle;
765 uint32 level;
766 NEW_BUFFER *buffer;
767 uint32 offered;
768 } SPOOL_Q_GETPRINTER;
770 typedef struct printer_info_info
772 union {
773 PRINTER_INFO_0 *info0;
774 PRINTER_INFO_1 *info1;
775 PRINTER_INFO_2 *info2;
776 void *info;
777 } printer;
778 } PRINTER_INFO;
780 typedef struct spool_r_getprinter
782 NEW_BUFFER *buffer;
783 uint32 needed;
784 uint32 status;
786 } SPOOL_R_GETPRINTER;
788 struct s_notify_info_data_table
790 uint16 type;
791 uint16 field;
792 char *name;
793 uint32 size;
794 void (*fn) (int snum, SPOOL_NOTIFY_INFO_DATA *data, print_queue_struct *queue, NT_PRINTER_INFO_LEVEL *printer);
797 typedef struct driver_info_1
799 UNISTR name;
800 } DRIVER_INFO_1;
802 typedef struct driver_info_2
804 uint32 version;
805 UNISTR name;
806 UNISTR architecture;
807 UNISTR driverpath;
808 UNISTR datafile;
809 UNISTR configfile;
810 } DRIVER_INFO_2;
812 typedef struct driver_info_3
814 uint32 version;
815 UNISTR name;
816 UNISTR architecture;
817 UNISTR driverpath;
818 UNISTR datafile;
819 UNISTR configfile;
820 UNISTR helpfile;
821 UNISTR **dependentfiles;
822 UNISTR monitorname;
823 UNISTR defaultdatatype;
824 } DRIVER_INFO_3;
826 typedef struct driver_info_info
828 union {
829 DRIVER_INFO_1 *info1;
830 DRIVER_INFO_2 *info2;
831 DRIVER_INFO_3 *info3;
832 } driver;
834 } DRIVER_INFO;
836 typedef struct spool_q_getprinterdriver2
838 POLICY_HND handle;
839 uint32 architecture_ptr;
840 UNISTR2 architecture;
841 uint32 level;
842 NEW_BUFFER *buffer;
843 uint32 offered;
844 uint32 unknown;
845 } SPOOL_Q_GETPRINTERDRIVER2;
847 typedef struct spool_r_getprinterdriver2
849 NEW_BUFFER *buffer;
850 uint32 needed;
851 uint32 unknown0;
852 uint32 unknown1;
853 uint32 status;
854 } SPOOL_R_GETPRINTERDRIVER2;
857 typedef struct add_jobinfo_1
859 UNISTR path;
860 uint32 job_number;
861 } ADD_JOBINFO_1;
864 typedef struct spool_q_addjob
866 POLICY_HND handle;
867 uint32 level;
868 NEW_BUFFER *buffer;
869 uint32 offered;
870 } SPOOL_Q_ADDJOB;
872 typedef struct spool_r_addjob
874 uint32 status;
875 } SPOOL_R_ADDJOB;
878 * I'm really wondering how many different time formats
879 * I will have to cope with
881 * JFM, 09/13/98 In a mad mood ;-(
883 typedef struct systemtime
885 uint16 year;
886 uint16 month;
887 uint16 dayofweek;
888 uint16 day;
889 uint16 hour;
890 uint16 minute;
891 uint16 second;
892 uint16 milliseconds;
893 } SYSTEMTIME;
895 typedef struct s_job_info_1
897 uint32 jobid;
898 UNISTR printername;
899 UNISTR machinename;
900 UNISTR username;
901 UNISTR document;
902 UNISTR datatype;
903 UNISTR text_status;
904 uint32 status;
905 uint32 priority;
906 uint32 position;
907 uint32 totalpages;
908 uint32 pagesprinted;
909 SYSTEMTIME submitted;
910 } JOB_INFO_1;
912 typedef struct s_job_info_2
914 uint32 jobid;
915 UNISTR printername;
916 UNISTR machinename;
917 UNISTR username;
918 UNISTR document;
919 UNISTR notifyname;
920 UNISTR datatype;
921 UNISTR printprocessor;
922 UNISTR parameters;
923 UNISTR drivername;
924 DEVICEMODE *devmode;
925 UNISTR text_status;
926 /* SEC_DESC sec_desc;*/
927 uint32 status;
928 uint32 priority;
929 uint32 position;
930 uint32 starttime;
931 uint32 untiltime;
932 uint32 totalpages;
933 uint32 size;
934 SYSTEMTIME submitted;
935 uint32 timeelapsed;
936 uint32 pagesprinted;
937 } JOB_INFO_2;
939 typedef struct spool_q_enumjobs
941 POLICY_HND handle;
942 uint32 firstjob;
943 uint32 numofjobs;
944 uint32 level;
945 NEW_BUFFER *buffer;
946 uint32 offered;
947 } SPOOL_Q_ENUMJOBS;
949 typedef struct job_info_ctr_info
951 union {
952 JOB_INFO_1 **job_info_1;
953 JOB_INFO_2 **job_info_2;
954 void *info;
955 } job;
957 } JOB_INFO_CTR;
959 typedef struct spool_r_enumjobs
961 NEW_BUFFER *buffer;
962 uint32 needed;
963 uint32 returned;
964 uint32 status;
965 } SPOOL_R_ENUMJOBS;
967 typedef struct spool_q_schedulejob
969 POLICY_HND handle;
970 uint32 jobid;
971 } SPOOL_Q_SCHEDULEJOB;
973 typedef struct spool_r_schedulejob
975 uint32 status;
976 } SPOOL_R_SCHEDULEJOB;
978 typedef struct s_port_info_1
980 UNISTR port_name;
981 } PORT_INFO_1;
983 typedef struct s_port_info_2
985 UNISTR port_name;
986 UNISTR monitor_name;
987 UNISTR description;
988 uint32 port_type;
989 uint32 reserved;
990 } PORT_INFO_2;
992 typedef struct spool_q_enumports
994 uint32 name_ptr;
995 UNISTR2 name;
996 uint32 level;
997 NEW_BUFFER *buffer;
998 uint32 offered;
999 } SPOOL_Q_ENUMPORTS;
1001 typedef struct port_info_ctr_info
1003 union {
1004 PORT_INFO_1 *info_1;
1005 PORT_INFO_2 *info_2;
1006 } port;
1008 } PORT_INFO_CTR;
1010 typedef struct spool_r_enumports
1012 NEW_BUFFER *buffer;
1013 uint32 needed; /* bytes needed */
1014 uint32 returned; /* number of printers */
1015 uint32 status;
1016 } SPOOL_R_ENUMPORTS;
1018 #define JOB_CONTROL_PAUSE 1
1019 #define JOB_CONTROL_RESUME 2
1020 #define JOB_CONTROL_CANCEL 3
1021 #define JOB_CONTROL_RESTART 4
1022 #define JOB_CONTROL_DELETE 5
1024 typedef struct job_info_info
1026 union {
1027 JOB_INFO_1 job_info_1;
1028 JOB_INFO_2 job_info_2;
1029 } job;
1031 } JOB_INFO;
1033 typedef struct spool_q_setjob
1035 POLICY_HND handle;
1036 uint32 jobid;
1037 uint32 level;
1038 JOB_INFO ctr;
1039 uint32 command;
1041 } SPOOL_Q_SETJOB;
1043 typedef struct spool_r_setjob
1045 uint32 status;
1047 } SPOOL_R_SETJOB;
1049 typedef struct spool_q_enumprinterdrivers
1051 uint32 name_ptr;
1052 UNISTR2 name;
1053 uint32 environment_ptr;
1054 UNISTR2 environment;
1055 uint32 level;
1056 NEW_BUFFER *buffer;
1057 uint32 offered;
1058 } SPOOL_Q_ENUMPRINTERDRIVERS;
1060 typedef struct spool_r_enumprinterdrivers
1062 NEW_BUFFER *buffer;
1063 uint32 needed;
1064 uint32 returned;
1065 uint32 status;
1066 } SPOOL_R_ENUMPRINTERDRIVERS;
1068 typedef struct spool_form_1
1070 uint32 flag;
1071 UNISTR name;
1072 uint32 width;
1073 uint32 length;
1074 uint32 left;
1075 uint32 top;
1076 uint32 right;
1077 uint32 bottom;
1078 } FORM_1;
1080 typedef struct spool_q_enumforms
1082 POLICY_HND handle;
1083 uint32 level;
1084 NEW_BUFFER *buffer;
1085 uint32 offered;
1086 } SPOOL_Q_ENUMFORMS;
1088 typedef struct spool_r_enumforms
1090 NEW_BUFFER *buffer;
1091 uint32 needed;
1092 uint32 numofforms;
1093 uint32 status;
1094 } SPOOL_R_ENUMFORMS;
1097 typedef struct spool_printer_info_level_2
1099 uint32 servername_ptr;
1100 uint32 printername_ptr;
1101 uint32 sharename_ptr;
1102 uint32 portname_ptr;
1103 uint32 drivername_ptr;
1104 uint32 comment_ptr;
1105 uint32 location_ptr;
1106 uint32 devmode_ptr;
1107 uint32 sepfile_ptr;
1108 uint32 printprocessor_ptr;
1109 uint32 datatype_ptr;
1110 uint32 parameters_ptr;
1111 uint32 secdesc_ptr;
1112 uint32 attributes;
1113 uint32 priority;
1114 uint32 default_priority;
1115 uint32 starttime;
1116 uint32 untiltime;
1117 uint32 status;
1118 uint32 cjobs;
1119 uint32 averageppm;
1120 UNISTR2 servername;
1121 UNISTR2 printername;
1122 UNISTR2 sharename;
1123 UNISTR2 portname;
1124 UNISTR2 drivername;
1125 UNISTR2 comment;
1126 UNISTR2 location;
1127 UNISTR2 sepfile;
1128 UNISTR2 printprocessor;
1129 UNISTR2 datatype;
1130 UNISTR2 parameters;
1131 SEC_DESC_BUF *secdesc;
1132 } SPOOL_PRINTER_INFO_LEVEL_2;
1134 typedef struct spool_printer_info_level
1136 uint32 level;
1137 uint32 info_ptr;
1138 SPOOL_PRINTER_INFO_LEVEL_2 *info_2;
1139 } SPOOL_PRINTER_INFO_LEVEL;
1141 typedef struct spool_printer_driver_info_level_3
1143 uint32 cversion;
1144 uint32 name_ptr;
1145 uint32 environment_ptr;
1146 uint32 driverpath_ptr;
1147 uint32 datafile_ptr;
1148 uint32 configfile_ptr;
1149 uint32 helpfile_ptr;
1150 uint32 monitorname_ptr;
1151 uint32 defaultdatatype_ptr;
1152 uint32 dependentfilessize;
1153 uint32 dependentfiles_ptr;
1155 UNISTR2 name;
1156 UNISTR2 environment;
1157 UNISTR2 driverpath;
1158 UNISTR2 datafile;
1159 UNISTR2 configfile;
1160 UNISTR2 helpfile;
1161 UNISTR2 monitorname;
1162 UNISTR2 defaultdatatype;
1163 BUFFER5 dependentfiles;
1165 } SPOOL_PRINTER_DRIVER_INFO_LEVEL_3;
1167 typedef struct spool_printer_driver_info_level
1169 uint32 level;
1170 uint32 ptr;
1171 SPOOL_PRINTER_DRIVER_INFO_LEVEL_3 *info_3;
1172 } SPOOL_PRINTER_DRIVER_INFO_LEVEL;
1175 /* this struct is undocumented */
1176 /* thanks to the ddk ... */
1177 typedef struct spool_user_level_1
1179 uint32 size;
1180 uint32 client_name_ptr;
1181 uint32 user_name_ptr;
1182 uint32 build;
1183 uint32 major;
1184 uint32 minor;
1185 uint32 processor;
1186 UNISTR2 client_name;
1187 UNISTR2 user_name;
1188 } SPOOL_USER_LEVEL_1;
1190 typedef struct spool_user_level
1192 SPOOL_USER_LEVEL_1 *user_level_1;
1193 } SPOOL_USER_LEVEL;
1195 typedef struct spool_q_setprinter
1197 POLICY_HND handle;
1198 uint32 level;
1199 SPOOL_PRINTER_INFO_LEVEL info;
1200 DEVMODE_CTR devmode_ctr;
1202 /* lkclXXXX jean-francois, see SEC_DESC_BUF code */
1203 struct
1205 uint32 size_of_buffer;
1206 uint32 data;
1207 } security;
1209 uint32 command;
1211 } SPOOL_Q_SETPRINTER;
1213 typedef struct spool_r_setprinter
1215 uint32 status;
1216 } SPOOL_R_SETPRINTER;
1218 typedef struct spool_q_addprinter
1220 UNISTR2 server_name;
1221 uint32 level;
1222 SPOOL_PRINTER_INFO_LEVEL info;
1223 uint32 unk0;
1224 uint32 unk1;
1225 uint32 unk2;
1226 uint32 unk3;
1227 uint32 user_level;
1228 SPOOL_USER_LEVEL user;
1229 } SPOOL_Q_ADDPRINTER;
1231 typedef struct spool_r_addprinter
1233 uint32 status;
1234 } SPOOL_R_ADDPRINTER;
1237 typedef struct spool_q_addprinterex
1239 uint32 server_name_ptr;
1240 UNISTR2 server_name;
1241 uint32 level;
1242 SPOOL_PRINTER_INFO_LEVEL info;
1243 uint32 unk0;
1244 uint32 unk1;
1245 uint32 unk2;
1246 uint32 unk3;
1247 uint32 user_switch;
1248 SPOOL_USER_CTR user_ctr;
1249 } SPOOL_Q_ADDPRINTEREX;
1251 typedef struct spool_r_addprinterex
1253 POLICY_HND handle;
1254 uint32 status;
1255 } SPOOL_R_ADDPRINTEREX;
1258 typedef struct spool_q_addprinterdriver
1260 uint32 server_name_ptr;
1261 UNISTR2 server_name;
1262 uint32 level;
1263 SPOOL_PRINTER_DRIVER_INFO_LEVEL info;
1264 } SPOOL_Q_ADDPRINTERDRIVER;
1266 typedef struct spool_r_addprinterdriver
1268 uint32 status;
1269 } SPOOL_R_ADDPRINTERDRIVER;
1272 typedef struct driver_directory_1
1274 UNISTR name;
1275 } DRIVER_DIRECTORY_1 ;
1277 typedef struct driver_info_ctr_info
1279 union {
1280 DRIVER_DIRECTORY_1 info_1;
1281 } driver;
1282 } DRIVER_DIRECTORY_CTR;
1284 typedef struct spool_q_getprinterdriverdirectory
1286 uint32 name_ptr;
1287 UNISTR2 name;
1288 uint32 environment_ptr;
1289 UNISTR2 environment;
1290 uint32 level;
1291 NEW_BUFFER *buffer;
1292 uint32 offered;
1293 } SPOOL_Q_GETPRINTERDRIVERDIR;
1295 typedef struct spool_r_getprinterdriverdirectory
1297 NEW_BUFFER *buffer;
1298 uint32 needed;
1299 uint32 status;
1300 } SPOOL_R_GETPRINTERDRIVERDIR;
1302 typedef struct spool_q_enumprintprocessors
1304 uint32 name_ptr;
1305 UNISTR2 name;
1306 uint32 environment_ptr;
1307 UNISTR2 environment;
1308 uint32 level;
1309 NEW_BUFFER *buffer;
1310 uint32 offered;
1311 } SPOOL_Q_ENUMPRINTPROCESSORS;
1313 typedef struct printprocessor_1
1315 UNISTR name;
1316 } PRINTPROCESSOR_1;
1318 typedef struct spool_r_enumprintprocessors
1320 NEW_BUFFER *buffer;
1321 uint32 needed;
1322 uint32 returned;
1323 uint32 status;
1324 } SPOOL_R_ENUMPRINTPROCESSORS;
1326 typedef struct spool_q_enumprintprocdatatypes
1328 uint32 name_ptr;
1329 UNISTR2 name;
1330 uint32 processor_ptr;
1331 UNISTR2 processor;
1332 uint32 level;
1333 NEW_BUFFER *buffer;
1334 uint32 offered;
1335 } SPOOL_Q_ENUMPRINTPROCDATATYPES;
1337 typedef struct ppdatatype_1
1339 UNISTR name;
1340 } PRINTPROCDATATYPE_1;
1342 typedef struct spool_r_enumprintprocdatatypes
1344 NEW_BUFFER *buffer;
1345 uint32 needed;
1346 uint32 returned;
1347 uint32 status;
1348 } SPOOL_R_ENUMPRINTPROCDATATYPES;
1350 typedef struct printmonitor_1
1352 UNISTR name;
1353 } PRINTMONITOR_1;
1355 typedef struct printmonitor_2
1357 UNISTR name;
1358 UNISTR environment;
1359 UNISTR dll_name;
1360 } PRINTMONITOR_2;
1362 typedef struct spool_q_enumprintmonitors
1364 uint32 name_ptr;
1365 UNISTR2 name;
1366 uint32 level;
1367 NEW_BUFFER *buffer;
1368 uint32 offered;
1369 } SPOOL_Q_ENUMPRINTMONITORS;
1371 typedef struct spool_r_enumprintmonitors
1373 NEW_BUFFER *buffer;
1374 uint32 needed;
1375 uint32 returned;
1376 uint32 status;
1377 } SPOOL_R_ENUMPRINTMONITORS;
1380 typedef struct spool_q_enumprinterdata
1382 POLICY_HND handle;
1383 uint32 index;
1384 uint32 valuesize;
1385 uint32 datasize;
1386 } SPOOL_Q_ENUMPRINTERDATA;
1388 typedef struct spool_r_enumprinterdata
1390 uint32 valuesize;
1391 uint16 *value;
1392 uint32 realvaluesize;
1393 uint32 type;
1394 uint32 datasize;
1395 uint8 *data;
1396 uint32 realdatasize;
1397 uint32 status;
1398 } SPOOL_R_ENUMPRINTERDATA;
1400 typedef struct spool_q_setprinterdata
1402 POLICY_HND handle;
1403 UNISTR2 value;
1404 uint32 type;
1405 uint32 max_len;
1406 uint8 *data;
1407 uint32 real_len;
1408 uint32 numeric_data;
1409 } SPOOL_Q_SETPRINTERDATA;
1411 typedef struct spool_r_setprinterdata
1413 uint32 status;
1414 } SPOOL_R_SETPRINTERDATA;
1416 typedef struct _form
1418 uint32 flags;
1419 uint32 name_ptr;
1420 uint32 size_x;
1421 uint32 size_y;
1422 uint32 left;
1423 uint32 top;
1424 uint32 right;
1425 uint32 bottom;
1426 UNISTR2 name;
1427 } FORM;
1429 typedef struct spool_q_addform
1431 POLICY_HND handle;
1432 uint32 level;
1433 uint32 level2;
1434 FORM form;
1435 } SPOOL_Q_ADDFORM;
1437 typedef struct spool_r_addform
1439 uint32 status;
1440 } SPOOL_R_ADDFORM;
1442 typedef struct spool_q_setform
1444 POLICY_HND handle;
1445 UNISTR2 name;
1446 uint32 level;
1447 uint32 level2;
1448 FORM form;
1449 } SPOOL_Q_SETFORM;
1451 typedef struct spool_r_setform
1453 uint32 status;
1454 } SPOOL_R_SETFORM;
1456 typedef struct spool_q_getjob
1458 POLICY_HND handle;
1459 uint32 jobid;
1460 uint32 level;
1461 NEW_BUFFER *buffer;
1462 uint32 offered;
1463 } SPOOL_Q_GETJOB;
1465 typedef struct pjob_info_info
1467 union {
1468 JOB_INFO_1 *job_info_1;
1469 JOB_INFO_2 *job_info_2;
1470 void *info;
1471 } job;
1473 } PJOB_INFO;
1475 typedef struct spool_r_getjob
1477 NEW_BUFFER *buffer;
1478 uint32 needed;
1479 uint32 status;
1480 } SPOOL_R_GETJOB;
1482 #define PRINTER_DRIVER_VERSION 2
1483 #define PRINTER_DRIVER_ARCHITECTURE "Windows NT x86"
1486 #endif /* _RPC_SPOOLSS_H */