Array column type of Xml type for Http calls

Hi I just want to know how to send XML data to Http post method in Objective-C dynamically instead of a static string. Adding

here's my sample xml Data:

<xml-packet version="2.5" ctr="1" timestamp="1345193301000">
<device id="0" name="hh" ipaddr="0.0.0.1" type="Hello" status="NORMAL" 
capability="ios">
<devcice name="5s" type="2" status="NORMAL">
<sensor name="sample" type="" status="NORMAL">
<event timestamp="1345193300000" type="ITEM">
<position agid="3" name="Manager" lastsynctime="1344433367000" action="" />
<position agid="6" name="LOC3" lastsynctime="1343818867000" action="" />
<position agid="8" name="LOC5" lastsynctime="1344433367000" action="" />
<position agid="4" name="LOC1" lastsynctime="1344504045000" action="" />
<position agid="5" name="LOC2" lastsynctime="1343386683000" action="" />
<position agid="7" name="LOC4" lastsynctime="1344238182000" action="" />

</event>
<event timestamp="1345192938000" type="ITEM">
<position agid="1" name="CEO" lastsynctime="1344594202000" action="update">
 <item id="ac001520101217000a012222" result="" status="NEW" lastmodifiedtime="" />
 <item id="e20019838306016127500770" result="" status="NEW" lastmodifiedtime="" />
 <item id="e20019838309014424301e64" result="" status="NEW" lastmodifiedtime="" />
 <item id="2005790000000000000005fc" result="" status="MISSING" lastmodifiedtime="1345212728000" />
 <item id="00000000012102007400bd39" result="" status="MISSING" lastmodifiedtime="1344594171000" />
</position>
</event>
</sensor>
</device>
</xml-packet>

      

+3


source to share





All Articles