我與以下請求和響應一類服務棧服務在相同的命名空間服務參考產生一個不正確的代理爲ServiceStack
public class GetContactMasterData
{
}
public class GetContactMasterDataResponse
{
public IdDescription[] EntityTypes { get; set; }
public IdDescription[] NameTypes { get; set; }
public IdDescription[] AddressTypes { get; set; }
public ResponseStatus MyResponseStatus { get; set; }
}
我測試的服務成功使用的soapUI。這是響應
<s:Envelope xmlns:s="http://www.w3.org/2003/05/soap-envelope">
<s:Body>
<GetContactMasterDataResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.servicestack.net/types">
<AddressTypes>
<IdDescription>
<Description>Home</Description>
<Id>1</Id>
</IdDescription>
...
</AddressTypes>
<EntityTypes>
<IdDescription>
<Description>Corporation</Description>
<Id>1</Id>
</IdDescription>
...
</EntityTypes>
<MyResponseStatus i:nil="true" />
<NameTypes>
<IdDescription>
<Id>4</Id>
<Description>Other</Description>
</IdDescription>
...
</NameTypes>
</GetContactMasterDataResponse>
</s:Body>
</s:Envelope>
當我創建一個控制檯應用程序中測試該服務的服務參考生成代理對象。這是智能感知如何引導你調用GetContactMasterData方法
GetContactMasterData(出IdDescription [],出ResponseStatus myResponseStatus,出IdDescription [] NameTypes):IdDescription [] addressTypes
我的問題是: 爲什麼EntityTypes和NameTypes變成輸出參數vs addressTypes成爲方法的返回類型?