This is version 0.87 of MKNetworkKit. Read the blog post for more. The latest code is still not fully testing on Mac, though iOS is complete. Caching responses and invalidation of cache is not implemented the right way for the Mac target.
MKNetworkKit is ready for production use on iOS apps. As on date, it's used by several thousands of apps including Digg
###Why MKNetworkKit?
- Single network queue for the whole app
- Auto queue sizing and auto network indicator support
- High performance background caching (based on HTTP 1.1 caching specs) built in
- You don't need a separate image cache library
- Background image decompression
- Performs exactly one operation for similar requests
- Background completion
- Local notification support for operations that failed in background
- cURL-able debug lines
- Frozen operations. Operations like "faving a tweet" or "marking as read" are frozen when network connectivity is not available and executed when online
These are just a few of most interesting features on MKNetworkKit.
###Installation
The preferred way of installation is via CocoaPods. Just add
pod 'MKNetworkKit'
and run pod install
. It will install the most recent version of MKNetworkKit.
If you would like to use the latest code of MKNetworkKit use:
pod 'MKNetworkKit', :head
###How to use Read the blog post for more.
###Licensing
MKNetworkKit is licensed under MIT License Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
###Attribution free licensing In case you need attribution free licensing for MKNetworkKit, you can buy one from my license store.
Install appledoc from gentlebytes github repo run this on the command line /usr/local/bin/appledoc --project-name MKNetworkKit -v 0.8 --project-company Steinlogic --company-id com.steinlogic.mknetworkkit -o ./Documentation -i .m -s ./MKNetworkKit .
####AppleDoc License appledoc is licensed with modified BSD license. In plain language: you're allowed to do whatever you wish with the code, modify, redistribute, embed in your products (free or commercial), but you must include copyright, terms of usage and disclaimer as stated in the license, the same way as any other BSD licensed code. You can of course use documentation generated by appledoc for your products (free or commercial), but you must attribute appledoc either in documentation itself or other appropriate place such as your website.
If for whatever reason you cannot agree to these terms, contact us through contact form on our about page, we'll do our best to help you out you out and find a workable solution!
Copyright (c) 2009-2011, Gentle Bytes All rights reserved.
Redistribution and use in source, binary forms and generated documentation, with or without modification, are permitted provided that the following conditions are met:
Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
Redistributions of documentation generated by appledoc must include attribution to appledoc, either in documentation itself or other appropriate media.
Neither the name of the appledoc, Gentle Bytes nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Gentle Bytes appledoc@gentlebytes.com
###TODO
- Streaming post body test
- Twitter streams test
- multiple images upload test
- Hash implementation for MKNetworkOperation
- Batch network queue
- A rare crash in setCache method (Multiple issues on Github that I cannot reproduce)
- Frozen operations should report via NSNotifications
###Known Issues
- Frozen operations don't report progress/completion handlers back to the calling code. (Before 1.0)
###Contract work I run a single man consulting and training company, Steinlogic and I'm available for contracting. If you want to make the web services layer of your iOS app super fast and responsive and give an unique experience to your users, we can help. Feel free to contact me through our web page. We also offer consulting services where we make the web services layer and other lower cost developers from developing countries help you with polishing the UI. Email us and we will take it up from there.