IMDSPStorage::GetRights method (mswmdm.h)

The GetRights method retrieves the rights information for an object.

Syntax

HRESULT GetRights(
  PWMDMRIGHTS *ppRights,
  UINT        *pnRightsCount,
  BYTE [8]    abMac
);

Parameters

ppRights

Pointer to an array of WMDMRIGHTS structures that contain the storage object rights information. This parameter is included in the output message authentication code.

pnRightsCount

Pointer to the number of WMDMRIGHTS structures in the ppRights array. This parameter is included in the output message authentication code.

abMac

Array of eight bytes containing the message authentication code for the parameter data of this method. (WMDM_MAC_LENGTH is defined as 8.)

Return value

The method returns an HRESULT. All the interface methods in Windows Media Device Manager can return any of the following classes of error codes:

  • Standard COM error codes
  • Windows error codes converted to HRESULT values
  • Windows Media Device Manager error codes
For an extensive list of possible error codes, see Error Codes.

Remarks

Object rights describe the usage permissions for media content. For example, the WMDMRIGHTS structure can contain information concerning how many times a file can be played and who can play it.

The ppRights array is allocated by this method, and must be freed by the application using CoTaskMemFree, a standard Win32 function.

This method is optional. For more information, see Mandatory and Optional Interfaces.

Requirements

   
Target Platform Windows
Header mswmdm.h
Library Mssachlp.lib

See also

IMDSPStorage Interface

WMDMRIGHTS