Skip to content

Commit 8102781

Browse files
committed
added more description in README.md
1 parent 89de598 commit 8102781

File tree

4 files changed

+27
-2
lines changed

4 files changed

+27
-2
lines changed

README.md

Lines changed: 26 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,31 @@
11
# SwiftyJSONAccelerator
22

3-
**Currenty In Development**
3+
**(Alpha v0.0.1)**
44

5-
A swift model generator like the Objective-C JSONAccelerator. Formats and generates models for the given JSON and also breaks them into files making it easy to manage and share between several models.
5+
A swift model generator like the Objective-C [JSONAccelerator](http://nerdery.com/json-accelerator). Formats and generates models for the given JSON and also breaks them into files making it easy to manage and share between several models. it relies on [SwiftyJSON](https://github.com/SwiftyJSON/SwiftyJSON) and requires you to include it in your project.
66

7+
Currently, the pattern is very similar to its Objective-C counterpart. It generates classes with following properties.
8+
9+
- Initalize with `JSON` (SwiftyJSON based)
10+
- Initalize with `AnyObject`
11+
- `NSCoding` compliant (Can be Archived using `NSKeyedArchiver`)
12+
- Convert to `NSDictionary`
13+
714
![Preview](https://raw.githubusercontent.com/insanoid/SwiftyJSONAccelerator/master/preview.png)
15+
(Simple configurable interface for generation of file)
16+
17+
![Preview](https://raw.githubusercontent.com/insanoid/SwiftyJSONAccelerator/master/preview_ii.png)
18+
(Files are generated individually making it more easy to use)
19+
20+
## TODO
21+
22+
- Instead of taking a single element consider merging all the elements and decide what to do as a while.
23+
- Should also consider the case where the type is an `[[AnyObject],[AnyObject]...]` while handling arrays.
24+
- Handle blank array a bit better.
25+
- Better User Interface
26+
- Generate both `struct` and `class`.
27+
- Support for generation of models that do not need SwiftyJSON.
28+
29+
---
30+
31+
This is one of my very first Swift projects, since I am used to developing models from JSON based APIs in Objective-C and there was no free tool to do this in Swift I created this (with ample inspiration from [SwiftJSON](https://github.com/swiftjson/SwiftJson) and[JSONAccelerator](http://nerdery.com/json-accelerator)). Any suggestions regarding code quality of the app, generated code's quaility, swift improvements and pull requests are all higly welcome.

SwiftyJSONAccelerator/SJModelGenerator.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -499,6 +499,7 @@ public class ModelGenerator {
499499
} catch {
500500
print(filename)
501501
}
502+
NSKeyedUnarchiver
502503
}
503504

504505
/**

preview.png

94.4 KB
Loading

preview_ii.png

22.6 KB
Loading

0 commit comments

Comments
 (0)