I am using NSURLConnection to download gzipped JSON from server. Is it possible to un-gzip received data with libraries that are part of iOS (Cocoa touch framework)?
I am somehow confused since a lot of people are pointing me to download some third party libraries?
I don't know for sure if there is built-in iOS functionality for this, but I know that a solid approach is to use ZipArchive. Also see this SO question, and this one.
Related
I am making an app that involves sending and receiving files from one iPhone to several other iPhones. I did a lot of googling and came nowhere in finding the classes that support the above said features. I am wondering whether it is possible and if it is possible what are the classes that i can use to do that
Take a look at my library https://github.com/abdullahselek/Merhaba
you can send data with Bonjour networking
I'm developing an ios application.
As part of my application I need to support upload of a small sized video created by the user (20 mb).
What would be the best way to approach the uploading? Should I handle it with a queue? Are there any built in libraries that support it?
Thanks
That depends on the version of iOS you are planning to deploy on. As of iOS 7, the NSURLSession class provide mechanisms to allow you to finish larger file transfers in background and pause them.
Follow the next links for more information:
https://developer.apple.com/library/mac/documentation/cocoa/conceptual/urlloadingsystem/Articles/UsingNSURLSession.html
https://developer.apple.com/library/ios/documentation/Foundation/Reference/NSURLSession_class/Introduction/Introduction.html
http://www.raywenderlich.com/51127/nsurlsession-tutorial
AFNetworking also provides very easy to use API around NSURLSession and it even supports older iOS versions (not their entire API though).
There is also some information in questions below:
How to work with large file uploads in ios?
AFNetworking + big download files + resume downloads
How to Transfer Large Files over wifi in iOS
If iOS7 support is enough for you, I would suggest using AFNetworking 2.0 library and following their best practices described in their extensive documentation at CocoaDocs.
If you do not want to use a library, go with Apple's built in class NSURLSession.
There is a library called AFNetworking.AFNetworking
Learning how to implement look here
Here are some examples
I'm building an application that needs to communicate with a REST service.
The application is using ARC so ASIHTTPRequest is NOT an option.
Also RESTKit horribly failed when we tried to use it.
How should we tackle sending the http request? (preferably asynchronicly) and 'storing' the data to be parsed by an XML parser (I don't really need help with that, just need to know how to feed it the data).
You don't need to use ARC everywhere, check out this question and answer, you could just disable ARC for the third party libraries.
Disable Automatic Reference Counting for Some Files
You can use AFNetworking its a very good Lib for REST communication protocol. And you can just disable ARC for AFNetworking as well.
I want to make an iPad app that
analyze the data traffic using: "tcpdump"
The app should be somehow a implementation/adaptation/wrapper
the/for the "tcpdump" command.
I zapped through the http://www.tcpdump.org/,
but I want to save time,
so I want ask you for some guidelines in order to solve this.
Is there any wrapper "libpcap" library for objective-c?
Or any other API that handles the "tcpdump" command in iOS.
How do I use a C/C++ library in an iPhone/iPad app?
Thanks in advance.
I didn't find an Obj-C wrapper for pcap either. Not surprising considering some points raised in this answer. #Guy Harris points out the problem specifically: unless you're running on a jailbroken device, you're going to be lacking the permissions to read the data.
This question (specifically this answer) suggests that you just properly name the files, then compile and link
Good luck.
I'm new to iOS, have been developing in Delphi for many years.
I don't know FPC well and i find it very hard to figure out which classes are available on iOS.
is there any FireMonkey classes for calling web services and parsing xml?
Yes you can call a webservice :)
No it is not simple :(
You need to access the iOS framework directly...
The following code fragments will help...
First a pascal example of how to send/receive data via TCP
https://forums.embarcadero.com/thread.jspa?messageID=397346
Secondly, you will need to wrap the call using the relevant headers. See...
http://books.google.com.au/books?id=0nTYIL3-0yoC&pg=PT518&lpg=PT518&dq=beginning+ipad+development+webservices&source=bl&ots=cYniLvL8z2&sig=Ci6HskHgMvUeIrjyUbDecd7fBCQ&hl=en&ei=0_KdTpzBB4nOrQfwzM29CQ&sa=X&oi=book_result&ct=result&resnum=6&ved=0CEAQ6AEwBQ#v=onepage&q&f=true
It is a fair bit of work, but it can be done. Good luck!
You can also try to use RealThinClient (RTC) SDK to allow your Delphi XE2 FireMonkey iOS client to connect to a RTC SDK server. Not SOAP, but I've managed to send data back and forth between the two layers (just in case you do not have to use SOAP, but are merely looking for some way to connect an iOS client to a server)...