You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
41 lines
803 B
41 lines
803 B
![]()
2 years ago
|
//
|
||
|
// MySingleton.h
|
||
|
// ProvinceAndCityAndTown
|
||
|
//
|
||
|
// Created by 冷求慧 on 16/12/27.
|
||
|
// Copyright © 2016年 冷求慧. All rights reserved.
|
||
|
//
|
||
|
|
||
|
#import <Foundation/Foundation.h>
|
||
|
#import "CityModelData.h" // 城市模型数据
|
||
|
|
||
|
@interface MySingleton : NSObject
|
||
|
|
||
|
+(instancetype)shareMySingleton;
|
||
|
|
||
|
/**
|
||
|
* 城市模型数据
|
||
|
*/
|
||
|
@property (nonatomic, strong) CityModelData *cityModel;
|
||
|
/**
|
||
|
* Json转为OC对象
|
||
|
*/
|
||
|
-(id)getObjectFromJsonString:(NSString *)jsonString;
|
||
|
/**
|
||
|
* 保存字段对应的值到本地
|
||
|
*
|
||
|
* @param fieldName 字段
|
||
|
* @param value 值
|
||
|
*/
|
||
|
+(void)saveLoacalWithField:(NSString *)fieldName value:(id)value;
|
||
|
/**
|
||
|
* 得到保存到本地对应字段的值
|
||
|
*
|
||
|
* @param fieldName 字段
|
||
|
*
|
||
|
* @return 值
|
||
|
*/
|
||
|
+(id)getsaveLoacalField:(NSString *)fieldName;
|
||
|
|
||
|
@end
|