No description, website, or topics provided.
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
LYModelData.xcodeproj
LYModelData
LYModelDataTests
LYModelDataUITests
README.md

README.md

使用

基本的Model 和 JSON相互转换

    NSString *girlFriend = @"白菜";
    id parmenters = @{
                      @"girlFriend":girlFriend,
                      @"age":@22.1,
                      @"name":@"Lastdays",
                      @"time":@"2016-03-18 5:55:49 +0000"
                      };
    
    
    Model *model = [Model LYModelWithJSON:parmenters];
    NSLog(@"%@",model.girlFriend);
    NSLog(@"%@",model.name);
    NSLog(@"%@",model.age);
    NSLog(@"%@",model.time);

    
    NSLog(@"========================================");
    
    NSDictionary *jsonObject= [model LYModelToJson];
    NSLog(@"%@",jsonObject);

欢迎指出问题