开发者

Connect iPhone to a Web Service?

New to iPhone develo开发者_StackOverflow中文版pment and working through exercises and examples to get me up to speed. Does anyone have a good reference for connecting an iPhone app to a website/webservice and push/pull data?


I have not used Core Resource yet, but it may be what you're looking for. It claims to provide (from the project's front page):

  1. Easy querying into a webservice, e.g.:

    [Note findAll:$D(@"Buster", @"author", @"createdAt DESC", @"$sort")];
    
  2. Automatic serialization of returned results into a Core Data context

  3. Easy resource-based tables using CoreTableController, e.g.:

    [self fetchForRelatedResource:parent withSort:@"lastName ASC"];
    


This one worked for me: SOAP/web services


If you have a wsdl file of the service you can use an automatic tool to build your service proxy and all the needed code in seconds.

SampleServiceProxy *proxy = [[SampleServiceProxy alloc]initWithUrl:@"YOUR
        URL" AndDelegate:self];
[proxy GetDouble];
[proxy GetEnum];
[proxy getEnum:kTestEnumTestEnum2];
[proxy GetInt16];
[proxy GetInt32];
[proxy GetInt64];
[proxy GetString];
[proxy getListStrings];
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜