ISCardCmd::p ut_ApduReply 方法
[ put_ApduReply 方法可用于“要求”部分中指定的操作系统。 它不适用于 Windows Server 2003 Service Pack 1 (SP1) 及更高版本、Windows Vista、Windows Server 2008 和操作系统的后续版本。 智能卡模块提供类似的功能。]
put_ApduReply 方法设置新的回复 APDU。
语法
HRESULT put_ApduReply(
[in] LPBYTEBUFFER pReplyApdu
);
parameters
-
pReplyApdu [in]
-
指向字节缓冲区的指针 (通过 IStream 对象) 映射,该对象包含返回时重播 APDU 消息。
返回值
方法返回以下可能值之一。
返回代码 | 说明 |
---|---|
|
操作已成功完成。 |
|
pReplyApdu 参数无效。 |
|
pReplyApdu 中传递了错误的指针。 |
|
内存不足。 |
备注
若要获取现有的回复 APDU,请调用 get_ApduReply。
有关此接口提供的所有方法的列表,请参阅 ISCardCmd。
除了上面列出的 COM 错误代码之外,如果调用智能卡函数来完成请求,则此接口可能返回智能卡错误代码。 有关详细信息,请参阅 智能卡返回值。
示例
以下示例演示如何设置新的 回复 APDU。 该示例假定 pIByteReply 是指向 IByteBuffer 实例的有效指针,pISCardCmd 是指向 ISCardCmd 接口实例的有效指针。
HRESULT hr;
// Set the reply data.
hr = pISCardCmd->put_ApduReply(pIByteReply);
if (FAILED(hr))
{
printf("Failed put_ApduReply.\n");
// Take other error handling action as needed.
}
要求
要求 | 值 |
---|---|
最低受支持的客户端 |
Windows XP [仅限桌面应用] |
最低受支持的服务器 |
Windows Server 2003 [仅限桌面应用] |
终止客户端支持 |
Windows XP |
终止服务器支持 |
Windows Server 2003 |
标头 |
|
类型库 |
|
DLL |
|
IID |
IID_ISCardCmd定义为 D5778AE3-43DE-11D0-9171-00AA00C18068 |
请参阅