operation 元素

指定要为其生成代码的作。

用法

<operation/>

属性

没有属性。

子元素

没有子元素。

父元素

元素 描述
functionDeclarations
为端口类型作的代理函数生成实现声明。

idlFunctionDeclarations
为端口类型作的代理函数生成 IDL 声明。

messageStructureDefinitions
生成消息类型的 C 结构定义。

messageTypeDeclarations
为消息类型的 XML 架构表生成 C 常量声明。

messageTypeDefinitions
为消息类型的 XML 架构表生成 C 常量。

portTypeDeclarations
为端口类型生成 C 常量声明。

portTypeDefinitions
为端口类型生成 C 常量。

proxyFunctionImplementations
为端口类型作的代理函数生成实现。

存根声明
为端口类型作的存根函数生成声明。

stubDefinitions
为端口类型作的存根函数生成实现。

subscriptionFunctionDeclarations
为端口类型通知作的订阅/取消订阅代理函数生成实现声明。

subscriptionIdlFunctionDeclarations
为端口类型通知作的订阅/取消订阅代理函数生成 IDL 声明。

subscriptionProxyFunctionImplementations
为端口类型通知作生成订阅/取消订阅代理函数的实现。

言论

可以指定任意数量的作。 如果未指定任何作,则会为所有相关端口类型中的所有作生成代码。 使用 元素将生成的方法限制为作中包含的方法。

例如,打印机支持以下作等:

  • PrintJobByPost
  • PrintJobByReference
  • CancelJob
  • GetJobElements
  • GetActiveJobs
  • GetJobHistory
  • SubscribeToPrinterConfigChange
  • UnsubscribeToPrinterConfigChange

但是,若要仅包含与 PrintJobByPostGetJobElements作相关的方法,代码生成脚本将使用 idlFunctionDeclarations 元素,如下所示:

<idlFunctionDeclarations>
    <operation>PrintJobByPost</operation>
    <operation>GetJobElements></operation>
</idlFunctionDeclarations>

这将生成与两个作关联的所有方法的 idl 函数声明(例如,BeginPrintJobByPostEndPrintJobByPostBeginGetJobElementsEndGetJobElements)。

元素信息

标签 价值
支持的最低系统
Windows Vista
可以为空 是的