0

応答から自動notificationRequestResponseノードのように見えるものを削除することは可能ですか?

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  ...
  <soap:Body>
    <notificationRequestResponse xmlns="...">
      <notificationResponse xmlns="...">
        <success xmlns="">boolean</success>
        <fault xmlns="">
          ...
        </fault>
      </notificationResponse>
    </notificationRequestResponse>
  </soap:Body>
</soap:Envelope>

以下を返す必要があります。

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  ...
  <soap:Body>
    <notificationResponse xmlns="...">
      <success xmlns="">boolean</success>
      <fault xmlns="">
        ...          
      </fault>
    </notificationResponse>
  </soap:Body>
</soap:Envelope>

notificationResponse をレスポンスのルートにしたい!

WebMethod には現在、ロジックはありませんが、次のとおりです。

return new notificationResponse()

notificationRequestResponse はどこから来ていますか? WebMethod SoapDocumentMethod(ResponseElementName="new name") を使用して名前を変更できますが、削除したいです。提供された仕様に取り組んでおり、選択の余地はありません。

感謝。

4

1 に答える 1