以下是 IBackgroundCopyJob5 接口的一些常用方法:
interface IBackgroundCopyJob5 : IBackgroundCopyJob4
{
HRESULT SetProperty(
[in] BITS_JOB_PROPERTY_ID propertyId,
[in] VARIANT *pValue
);
HRESULT GetProperty(
[in] BITS_JOB_PROPERTY_ID propertyId,
[out] VARIANT *pValue
);
HRESULT GetErrorCount(
[out] DWORD *Errors
);
HRESULT SetMaximumDownloadTime(
[in] ULONG Timeout
);
HRESULT GetMaximumDownloadTime(
[out] ULONG *pTimeout
);
HRESULT SetProperty2(
[in] BITS_JOB_PROPERTY_ID propertyId,
[in] VARIANT *pValue,
[in] BITS_JOB_PROPERTY_OPTIONS options
);
HRESULT GetProperty2(
[in] BITS_JOB_PROPERTY_ID propertyId,
[out] VARIANT *pValue,
[out] BITS_JOB_PROPERTY_OPTIONS *pOptions
);
HRESULT SetNotifyCmdLine(
[in] LPCWSTR Program,
[in] LPCWSTR Parameters
);
HRESULT GetNotifyCmdLine(
[out] LPWSTR *pProgram,
[out] LPWSTR *pParameters
);
};
请注意,这只是接口的一部分,具体的使用可能需要更多的代码和相关的初始化步骤。
转载请注明出处:http://www.zyzy.cn/article/detail/24057/Win32 API/Bits5_0.h/IBackgroundCopyJob5