Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/wcf/4.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

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/cocoa/3.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
WCF Rest初学者工具包OnGetItems:格式化IEnumerable<;KeyValuePair。。XML_Wcf_Rest - Fatal编程技术网

WCF Rest初学者工具包OnGetItems:格式化IEnumerable<;KeyValuePair。。XML

WCF Rest初学者工具包OnGetItems:格式化IEnumerable<;KeyValuePair。。XML,wcf,rest,Wcf,Rest,WCF Rest初学者工具包OnGetItems返回IEnumerable 在序列化时,它变为 <ItemInfoList> <ItemInfo> <EditLink>http://localhost:1394/BService.svc/1</EditLink> <Item> <Name>Foundations</Name> </Item> </ItemInfo> <ItemI

WCF Rest初学者工具包OnGetItems返回
IEnumerable

在序列化时,它变为

<ItemInfoList>

<ItemInfo>
<EditLink>http://localhost:1394/BService.svc/1</EditLink>

<Item>
<Name>Foundations</Name>
</Item>
</ItemInfo>

<ItemInfo>
<EditLink>http://localhost:1394/Service.svc/2</EditLink>

<Item>
<Name>Hitchhikers guide</Name>
</Item>
</ItemInfo>
</ItemInfoList>

http://localhost:1394/BService.svc/1
基础
http://localhost:1394/Service.svc/2
搭便车指南

我想将ItemInfo和ItemInfoList更改为更合理的名称,如业务实体名称。我该怎么做呢?

据我所知,您不能更改这些名称,因为REST kit为您提供了数据契约ItemInfosList和ItemInfo,所以您使用CollectionServiceBase放弃了一些控制