## Presentation Device Driver Reference for OS/2

[prev][next][parent][TOC]

### SplProtSendCmd Parameter - ulType

ulType (ULONG) - input Type of query and options.

Values are as follows:

TYPE_CACHE_ONLY(0) Returns information from the protocol converter or port driver's cache only. Does not send anything to the printer.

If the requested information is not available, ERROR_INFO_NOT_AVAIL is returned. The caller should reissue the command with a different ulType value.

TYPE_SHORT_WAIT(1) Returns information via a communications channel with the printer that can be used while a job is being sent to the printer.

An example would be using NPAP or SNMP. If the requested information cannot be returned using this type of channel (for instance, if a PJL command is required to get this information), ERROR_INFO_NOT_AVAIL is returned.

TYPE_LONG_WAIT(2) Returns information using any necessary communications channel with the printer, even if the request has to wait for the current job being sent to the printer to complete.

If the printer supports only one command channel, and this channel can be used while a job is being sent to the printer, TYPE_SHORT_WAIT(1) and TYPE_ LONG_WAIT(2) will behave in the same way.

TYPE_CACHE_UPDATE(3) Returns information from the protocol converter or port driver's cache and also updates the cache in the background.

This is an optional type of query to support and, if it is not supported, will return ERROR_INVALID_FUNCTION.

If the requested information is not available in the cache, ERROR_INFO_NOT_ AVAIL is returned. The caller should reissue the command with a different ulType value.

TYPE_WITHOUT_WRAPPER(4) Returns or sends passthru or alert information without any packet wrapper around it.

This is useful for BIDI_READ_PASSTHRU and BIDI_SEND_PASSTHRU as it allows an application to send and receive printer interpreter language commands without having to know the format of the BIDI protocol's data wrappers. An example would be removing the NPAP wrapper before returning Postscript response data to an application.

If BIDI_READ_PASSTHRU is used without this value, the calling application requests the data as the printer returns it, possibly with any data wrappers.

If BIDI_SEND_PASSTHRU is used without this value, the calling application must have already wrapped the passthru data.

Note: If this value is used with any command other than BIDI_READ_PASSTHRU , ERROR_INVALID_PARAMETER is returned.

TYPE_CACHE_WAIT(5) Returns information from the protocol converter or port driver's cache only. If the data is not available in the cache, use any mechanism available to get the information.

If TYPE_CACHE_WAIT(5) is not supported by the port driver or protocol converter, ERROR_INVALID_PARAMETER is returned.

The value of TYPE_CACHE_WAIT(5) may be used by the print object to issue BIDI_Q_STATUS, to get the current status of the printer without waiting to communicate with the printer.