Partager via


3.1.4.8.5 RpcEnumPrintProcessorDatatypes (Opnum 51)

RpcEnumPrintProcessorDatatypes enumerates the data types that a specified print processor supports.

 DWORD RpcEnumPrintProcessorDatatypes(
   [in, string, unique] STRING_HANDLE pName,
   [in, string, unique] wchar_t* pPrintProcessorName,
   [in] DWORD Level,
   [in, out, unique, size_is(cbBuf), disable_consistency_check] 
     BYTE* pDatatypes,
   [in] DWORD cbBuf,
   [out] DWORD* pcbNeeded,
   [out] DWORD* pcReturned
 );

pName: This parameter MUST adhere to the parameter specification in Print Server Name Parameters, section 3.1.4.1.4.

pPrintProcessorName: A pointer to a string that specifies the name of the print processor whose data types MUST be enumerated. For rules governing print processor names, see section 2.2.4.11.

Level: The value of this parameter MUST be 0x00000001.

pDatatypes: This parameter MAY be NULL if cbBuf equals zero; otherwise, it is a pointer to BUFFER as specified in INFO Structures Query Parameters, section 3.1.4.1.9.

BUFFER TYPE: _DATATYPES_INFO_1

cbBuf: This parameter MUST adhere to the parameter specification in INFO Structures Query Parameters, section 3.1.4.1.9.

pcbNeeded: This parameter MUST adhere to the parameter specification in INFO Structures Query Parameters, section 3.1.4.1.9.

pcReturned: This parameter MUST adhere to the parameter specification in INFO Structures Query Parameters, section 3.1.4.1.9.

Return Values: This method MUST return zero (ERROR_SUCCESS) to indicate successful completion or a nonzero Windows error code to indicate failure [MS-ERREF].

Upon receiving this message, the server MUST validate parameters as follows:

  • Perform the validation steps that are specified in Print Server Name Parameters, section 3.1.4.1.4.

  • Verify that the print processor that is identified by the string that is referenced by the pPrintProcessorName parameter is in the list of print processors.

  • Perform the validation steps that are specified in INFO Structures Query Parameters, section 3.1.4.1.9.

  • Additional validation MAY<375> be performed.

If parameter validation fails, the server MUST fail the operation immediately and return a nonzero error response to the client. Otherwise, the server MUST process the message and compose a response to the client as follows:

  • Enumerate all data types that are supported by the specified print processor.

  • Using the enumerated objects, perform the processing and response steps specified in INFO Structures Query Parameters, section 3.1.4.1.9.

  • Return the status of the operation.