小编man*_*nar的帖子

GDataXML使用xmlns命名空间写入文件

我正在使用GDataXML,我遇到了编写XML文件的一些问题.我按照Raywenderlich的教程,但我必须添加一些名称空间.

例如:
[FooElement addChild:bar1Element];
[FooElement addChild:bar2Element];
[FooElement addChild:bar3Element];
[FooElement addChild:bar4Element];

我想做类似的事情:
[FooElement addNamespace:@"xmlns ="https:// foo/bar /"

将此结果 存入文件:
<Foo xmlns ="https:// foo/bar /" >
<bar1> xxxx </ bar1>
<bar2> xxxx </ bar2>
<bar3> xxxx </ bar3>
<bar4> xxxx </ bar4>
</ Foo>

感谢帮助 !

namespaces xml-namespaces gdataxml

4
推荐指数
1
解决办法
1004
查看次数

标签 统计

gdataxml ×1

namespaces ×1

xml-namespaces ×1