@property (nonatomic,strong) NSArray *imageData;//定义一个数组

-(NSArray *)imageDate
{
if(_imageDate==nil)
{
NSMutableDictionary *image1=[NSMutableDictionary dictionary];
image1["icon"]=@"a";
image1["title"]=@"测试一"; NSMutableDictionary *image2=[NSMutableDictionary dictionary];
image2["icon"]=@"a";
image2["title"]=@"测试二"; NSMutableDictionary *image3=[NSMutableDictionary dictionary];
image3["icon"]=@"a";
image3["title"]=@"测试三";
_imageData=@[image1,image2,image3];
}
return _imageData;
}
//读取数据
NSDictionary *imageDict=self.imageData[];
self.icon.text=imageDict[@"icon"];
self.title.text=imageDict[@"title"];

 

最新文章

  1. MVC 解决 readonly 问题
  2. [MySQL] 高可用架构MMM简单介绍
  3. 健忘vs总结
  4. 【腾讯Bugly干货分享】Android ListView与RecyclerView对比浅析--缓存机制
  5. Codeforces Round #195 (Div. 2) A. Vasily the Bear and Triangle
  6. 获取ip
  7. Fortran学习心得
  8. 任意阶魔方阵(幻方)的算法及C语言实现
  9. C语言中的fread和fwrite
  10. SQL Server使用WITH AS递归查找
  11. Android(java)学习笔记129:Tab标签的使用
  12. Python新手学习基础之函数-概念与定义
  13. php 数组 array_values () array_key()
  14. Android 它们的定义ListView实现底部和页下拉刷新刷新的顶
  15. wildfly10报错2:ID注释有错
  16. 02-TypeScript中新的字符串
  17. Eclipse插件:Spket
  18. Project Euler 75: Singular integer right triangles
  19. P1057 传球游戏 dp
  20. 【Codeforces 710F】String Set Queries

热门文章

  1. 原生JS实现瀑布流布局
  2. fiddler 显示server ip
  3. python基础之字典以及增删改查
  4. MongoDB存储
  5. java getInstance()的使用
  6. vue3.0 配置公共请求地址
  7. Hadoop--单点故障修复
  8. linux因勿删或误操作导致登录界面异常,命令无法使用,显示/bin/bash:No such file or directory
  9. 函数后面跟throw
  10. spark使用正则表达式读入多个文件