zoukankan      html  css  js  c++  java
  • json数据解析

    1、ESJson Format和JSonModel配合使用自动生成的数据model

    AppealListModel.h文件

    #import <Foundation/Foundation.h>

    @class ComplaintlistItem;

    @interface AppealListModel : NSObject

    @property (nonatomic, assign) NSInteger IsSuccess;

    @property (nonatomic, assign) NSInteger RecordCount;

    @property (nonatomic, copy) NSString *ErrorMessage;

    @property (nonatomic, strong) NSArray<ComplaintlistItem *> *ComplaintList;

    @end

    @interface ComplaintlistItem : NSObject

    @property (nonatomic, copy) NSString *OrderID;

    @property (nonatomic, copy) NSString *YzName;

    @property (nonatomic, copy) NSString *ComplaintStateName;

    @property (nonatomic, assign) NSInteger ComplaintID;

    @property (nonatomic, assign) NSInteger Frequency;

    @property (nonatomic, copy) NSString *Content;

    @property (nonatomic, assign) NSInteger ComplaintState;

    @property (nonatomic, copy) NSString *CreateTime;

    @end

    AppealListModel.m文件

    #import "AppealListModel.h"

    @implementation AppealListModel

    + (NSDictionary *)objectClassInArray{

        return @{@"ComplaintList" : [ComplaintlistItem class]};

    }

    @end

    @implementation ComplaintlistItem

    @end

    2、JSonModel生成对象:

  • 相关阅读:
    EntityManager 实例化方法
    Java Jpa 规范
    Spring HandlerInterceptor
    Spring data jpa
    Spring Security @PreAuthorize 拦截无效
    Java ee el表达式
    脏读&幻读
    OR查询是否会使得索引失效?
    ThinkPHP中的parseDSN方法的坑记录一下
    js , map中的坑
  • 原文地址:https://www.cnblogs.com/Jordandan/p/6100644.html
Copyright © 2011-2022 走看看