3.2.4.2.45.20 GetModuleDefinition (Opnum 26)

The GetModuleDefinition method returns a pointer to the module definition with the specified Name and Module type from the List of Persisted Module Definitions (section 3.2.1.6).

 [id(FSRM_DISPID_CLASSIFICATION_MANAGER | 0x09)] HRESULT GetModuleDefinition(
   [in] BSTR moduleName,
   [in] FsrmPipelineModuleType moduleType,
   [out, retval] IFsrmPipelineModuleDefinition** moduleDefinition
 );

moduleName: Contains the name of the module definition to retrieve.

moduleType: Contains the type of the module definition to retrieve. For possible types, see the FsrmPipelineModuleType (section 2.2.1.2.12) enumeration.

moduleDefinition: An IFsrmPipelineModuleDefinition interface pointer (section 3.2.4.2.43) to the module definition. Query the IFsrmPipelineModuleDefinition interface to get the interface pointer for the specified module.

Return Values: The method MUST return zero on success, or a nonzero error code on failure.

Return value/code

Description

0x80045301

FSRM_E_NOT_FOUND

The specified module definition could not be found.

0x80045308

FSRM_E_INVALID_NAME

The specified name is empty or NULL.

0x80070057

E_INVALIDARG

This code is returned for the following reasons:

  • The moduleType parameter is not a valid FsrmPipelineModuleType (section 2.2.1.2.12) value.

  • The specified name exceeds the maximum length of 100 characters.

  • The moduleDefinitions parameter is NULL.

Upon receiving this message, the server MUST validate parameters:

  • Verify that moduleName is not empty or NULL and does not exceed the maximum length of 100 characters.

  • Verify that moduleDefinition is not NULL.

  • Verify that moduleType contains a valid FsrmPipelineModuleType value. If moduleType is FsrmPipelineModuleType_Unknown, the parameter MUST be considered an invalid value.

If any validation fails, the server MUST terminate processing and return a nonzero error code.

Upon successful validation of parameters, the server MUST perform the following actions.