2011-05-31 59 views
4

我能否在不編輯代碼的情況下更改所有SOAP Web服務方法中的名稱空間:SOAP Web服務,更改命名空間而不編輯代碼?

這條線......

<ConfirmIdentity xmlns="http://www.domain.com"> ? 

這可能嗎?

<?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> 
    <ConfirmIdentity xmlns="http://www.domain.com"> 
     <ConfirmIdentityRequest> 
     <ApplicationCrediential> 
      <API_Username>string</API_Username> 
      <API_Password>string</API_Password> 
     </ApplicationCrediential> 
     <SessionId>string</SessionId> 
     </ConfirmIdentityRequest> 
    </ConfirmIdentity> 
    </soap:Body> 
</soap:Envelope> 
+0

使用什麼語言創建Web服務? – balexandre 2011-05-31 17:13:56

+0

這是在C#中,但我不能編輯代碼:( – 001 2011-06-01 14:35:14

+0

爲什麼不讓你自己的消耗那個? – balexandre 2011-06-01 19:35:40

回答

1

據我所知,你不能改變命名空間,它是在類和方法的上下文中設置的。即使你以某種方式從另一個方面包裝它,它仍然會覆蓋。你只是一個代理消費者的選擇。