https://github.com/keith/ksqueryitem
A NSDictionary category to return NSURLQueryItems
https://github.com/keith/ksqueryitem
Last synced: 10 months ago
JSON representation
A NSDictionary category to return NSURLQueryItems
- Host: GitHub
- URL: https://github.com/keith/ksqueryitem
- Owner: keith
- License: mit
- Created: 2014-12-31T00:12:50.000Z (over 11 years ago)
- Default Branch: master
- Last Pushed: 2015-01-08T07:53:58.000Z (over 11 years ago)
- Last Synced: 2025-02-21T17:47:42.592Z (over 1 year ago)
- Language: Objective-C
- Homepage:
- Size: 199 KB
- Stars: 3
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# KSQueryItem
[](https://travis-ci.org/Keithbsmiley/KSQueryItem)
A simple `NSDictionary` category to return
[`NSURLQueryItems`][NSURLQueryItem] for use with
[`NSURLComponents`][NSURLComponents]
[NSURLQueryItem]: https://developer.apple.com/library/prerelease/ios/documentation/Foundation/Reference/NSURLQueryItem_Class/index.html
[NSURLComponents]: https://developer.apple.com/library/prerelease/ios/documentation/Foundation/Reference/NSURLComponents_class/index.html
## Usage
```objective-c
NSURLComponents *components = ...
NSDictionary *params = @{@"user": @"archer", @"password": @"guest"};
components.queryItems = [params ks_queryItems];
```
## Setup
### With [CocoaPods](http://cocoapods.org)
```ruby
pod "KSQueryItem", "~> 1.0.0"
```
Then (in your Bridging header for swift):
```objective-c
#import
```