从对象列表中.NET创建的plist [英] create Plist in .net from list of objects
问题描述
我的工作是喂养通过Web服务返回JSON数据的iPad应用程序。看着一些iTunes U的情节,它看起来像发回的plist可以节省我大量的时间,加快我的应用程序对事物的分析侧颇有几分。
I am working on an iPad app that is fed data via web service returning JSON. Watching some iTunes U episodes, it looks like sending back Plist would save me a ton of time and speed up my app quite a bit on the parsing side of things.
有谁知道,将对象转换成此plist中,而不是返回一个.NET库?
Does anyone know of a .net library that converts objects into this Plist to return instead?
编辑(这是我对这个话题的了解非常有限):
一个PLIST是一个属性列表的iOS可以用它来轻松地连接code和/或解析数据。这是非常相似的JSON除了解析花费的时间的一小部分,并且可以在1行code来完成。如果您的服务器使用的WebObjects编码,然后还可以在1号线code的做,我使用IIS,所以我需要一个解决方案,如果我之前写我自己一个人的存在。
EDIT (this is my very limited understanding of this topic): An Plist is a Property List that iOS can use to easily encode and/or parse data. It is very similar to JSON except parsing takes a fraction of the time and can be done in 1 line of code. If your server uses WebObjects then encoding can also be done in 1 line of code, I am using IIS so I need a solution for this if one exists before I write my own.
您可以看到这里的视频:
http://developer.apple.com/videos/wwdc/2010/
You can see the videos here: http://developer.apple.com/videos/wwdc/2010/
在特定的手表会话117 - 构建服务器驱动的用户体验。
In particular watch Session 117 - Building a Server-Driven User Experience
推荐答案
您可以签这个项目。示例用法:
object value = ...
string plist = Plist.PlistDocument.CreateDocument(value);
唯一的要求是 [序列化]
属性。
这篇关于从对象列表中.NET创建的plist的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!