包含前缀名称的属性值的含义

时间:2018-04-24 13:49:22

标签: xml

我有以下XML:

</wsdl:message>
<wsdl:message name="AdvancedVerifyEmailHttpGetIn">
<wsdl:part name="email" type="s:string"/>
<wsdl:part name="timeout" type="s:string"/>
<wsdl:part name="LicenseKey" type="s:string"/>
</wsdl:message>
<wsdl:operation name="AdvancedVerifyEmail">
<wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
This function will verify an email address and also includes the ability to timeout the verification process. The Verification can be slowed down by the email server being verified against. <b>Timeout is in seconds</b> Use a licensekey of 0 for testing <br> NOTE: A timeout error (7) does not mean an email will not go through. You should treat this as a good email address.
</wsdl:documentation>
**<wsdl:input message="tns:AdvancedVerifyEmailHttpGetIn"/**>
<wsdl:output message="tns:AdvancedVerifyEmailHttpGetOut"/>
</wsdl:operation>

突出显示的一个标签输入包含消息属性,其值为&#34; tns:AdvancedVerifyEmailHttpGetIn&#34;它有前缀命名空间。

请你帮我理解这是否意味着之前声明的消息是命名空间tns,还是只是消息属性引用消息,而输入的任何消息都将在tns命名空间中?

1 个答案:

答案 0 :(得分:1)

如果查看架构,您将看到message属性的类型为xs:QName。这基本上意味着它的行为类似于元素或属性名称:冒号前面的部分(“tns”)被解释为名称空间前缀,验证器检查此前缀是否已在某个外部祖先元素上正确声明。

相关问题