Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/xpath/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Soap 带名称空间的Xpath_Soap_Xpath_Namespaces - Fatal编程技术网

Soap 带名称空间的Xpath

Soap 带名称空间的Xpath,soap,xpath,namespaces,Soap,Xpath,Namespaces,我无法获得以下xpath查询的结果 代码如下所示 FileInputStream file=newfileinputstream(新文件(“D:/reservationresponse.xml”) 用于解析的XML: 这就是我试图解析的xml <?xml version="1.0" encoding="UTF-8"?> <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://sc

我无法获得以下xpath查询的结果

代码如下所示

FileInputStream file=newfileinputstream(新文件(“D:/reservationresponse.xml”)

用于解析的XML: 这就是我试图解析的xml

     <?xml version="1.0" encoding="UTF-8"?>
      <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:header="http://wsi.nat.qt.com/2005/06/StandardHeader/">
<SOAP-ENV:Body>
    <S18:reserveResourceResponse
        xsi:schemaLocation="http://capabilities.nat.qt.com/xsd/ManageResourceService/2009/05/01 ManageResourceServiceInterface.20090501.xsd"
        xmlns:S18="http://capabilities.nat.qt.com/xsd/ManageResourceService/2009/05/01"
        xmlns:S2="http://capabilities.nat.qt.com/xsd/ManageResourceService/2009/05/01/CCM/Agreements"
        xmlns:S16="http://capabilities.nat.qt.com/xsd/ManageResourceService/2009/05/01/MTOSI"
        xmlns:S8="http://capabilities.nat.qt.com/xsd/ManageResourceService/2009/05/01/MTOSI/Structs"
        xmlns:S11="http://capabilities.nat.qt.com/xsd/ManageResourceService/2009/05/01/NonCCM">
        <header:standardHeader>
            <header:e2e>
                <header:E2EDATA>10=2pzmw0etdv,1=2pzmwi65s6,7=apl08929imbwa2,6=PCK002069,4=RoBTESB-default,9=wlsuser,15=RoBTESB,8=UNKNOWN,1.2=APP10865:2pzmwi65s6:,1.1=APP10865:2pzmw0esr0:,16=LIMS
                </header:E2EDATA>
            </header:e2e>

10=2pzmw0etdv,1=2pzmwi65s6,7=apl08929imbwa2,6=PCK002069,4=RoBTESB默认值,9=wlsuser,15=RoBTESB,8=UNKNOWN,1.2=APP10865:2pzmwi65s6:,1.1=APP10865:2pzmw0esr0:,16=LIMS

结果为空

下面给出了xml片段。您的xml无效。请发布您遇到问题的有效代码段。不管怎样,为什么在查询的中间有空白,在<代码> /SOAP-Env:Boo/</代码>中?
     <?xml version="1.0" encoding="UTF-8"?>
      <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:header="http://wsi.nat.qt.com/2005/06/StandardHeader/">
<SOAP-ENV:Body>
    <S18:reserveResourceResponse
        xsi:schemaLocation="http://capabilities.nat.qt.com/xsd/ManageResourceService/2009/05/01 ManageResourceServiceInterface.20090501.xsd"
        xmlns:S18="http://capabilities.nat.qt.com/xsd/ManageResourceService/2009/05/01"
        xmlns:S2="http://capabilities.nat.qt.com/xsd/ManageResourceService/2009/05/01/CCM/Agreements"
        xmlns:S16="http://capabilities.nat.qt.com/xsd/ManageResourceService/2009/05/01/MTOSI"
        xmlns:S8="http://capabilities.nat.qt.com/xsd/ManageResourceService/2009/05/01/MTOSI/Structs"
        xmlns:S11="http://capabilities.nat.qt.com/xsd/ManageResourceService/2009/05/01/NonCCM">
        <header:standardHeader>
            <header:e2e>
                <header:E2EDATA>10=2pzmw0etdv,1=2pzmwi65s6,7=apl08929imbwa2,6=PCK002069,4=RoBTESB-default,9=wlsuser,15=RoBTESB,8=UNKNOWN,1.2=APP10865:2pzmwi65s6:,1.1=APP10865:2pzmw0esr0:,16=LIMS
                </header:E2EDATA>
            </header:e2e>