JSON Framework allowed by Apple?

Discussion in 'iOS Programming' started by 2Cheap2Switch, Jul 30, 2010.

  1. 2Cheap2Switch
    Expand Collapse
    macrumors member

    Joined:
    May 16, 2005
    Location:
    Stanford
    #1
    Hi, I was wondering if any posters on here have used the JSON framework mentioned on this page?

    http://blog.grio.com/2009/04/dealing-with-json-on-iphone.html

    and if apple approves/allows applications which use it? I have no experience with JSON, so if this framework is allowed it would make my life a lot easier.

    Thanks!
     
  2. namanhams
    Expand Collapse
    macrumors regular

    Joined:
    Jun 3, 2009
    #2
    Hi,

    I think as long as that framework doesn't use undocumented API, it should be no problem.
     
  3. seepel
    Expand Collapse
    macrumors 6502

    seepel

    Joined:
    Dec 22, 2009
    #3
    The iPhone programming class at Stanford actually recommends the JSON framework. Just make sure you don't link it dynamically. Either copy the source files themselves into your project, or include it as a static library.
     
  4. Luke Redpath
    Expand Collapse
    macrumors 6502a

    Joined:
    Nov 9, 2007
    Location:
    Colchester, UK
    #4
    There are a few different JSON options you can use. Here is an interesting performance comparison:

    http://samsoff.es/posts/updated-iphone-json-benchmarks

    Note that the Apple JSON framework is private and cannot be used.

    Its also worth noting that if you have control over the server side API and are able ti serve up your data in binary plist format, its an order of magnitude faster to both download and parse (there is some good data on this in one of the WWDC videos although I can't remember which im afraid.).
     
  5. 2Cheap2Switch
    Expand Collapse
    thread starter macrumors member

    Joined:
    May 16, 2005
    Location:
    Stanford
    #5
    I'm definitely going to try out the Touch JSON framework, but does apple approve applications that use it in their app store?
     
  6. Luke Redpath
    Expand Collapse
    macrumors 6502a

    Joined:
    Nov 9, 2007
    Location:
    Colchester, UK
    #6
    Yes, there is nothing stopping you from using third-party libraries as long as you statically link to them or import the source directly into your project. Its only dynamic linking and use of private Apple frameworks and APIs that is not allowed.
     
  7. 2Cheap2Switch
    Expand Collapse
    thread starter macrumors member

    Joined:
    May 16, 2005
    Location:
    Stanford
  8. firewood
    Expand Collapse
    macrumors 604

    Joined:
    Jul 29, 2003
    Location:
    Silicon Valley
    #8
    Unless the library you link to is an Adobe Flash runtime, or something Apple thinks is similar.
     

Share This Page