Commit ab995c8d authored by 李震's avatar 李震

驼峰命名

parent 305b363c
......@@ -9,11 +9,18 @@
@implementation GMShareBaseObject
+ (JSONKeyMapper*)keyMapper {
+ (JSONKeyMapper*)keyMapper
{
/**将类似"order_id": 104的json 解析成 @property (assign, nonatomic) int orderId;
即使修改为驼峰命名法
*/
return [JSONKeyMapper mapperFromUnderscoreCaseToCamelCase];
}
//所有的属性都是可选的,order_id即使为空,不会引起崩溃
+ (BOOL)propertyIsOptional:(NSString*)propertyName
{
return YES;
}
@end
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment