可根据rs.status() 查询集群服务器状态.字段解释:self
这个信息出现在执行rs.status()函数的成员信息中stateStr用户描述服务器状态的字符串。有SECONDARY,PRIMARY,RECOVERING等uptime
从成员可到达一直到现在经历的时间,单位是秒。optime...
分类:
其他好文 时间:
2014-06-07 05:23:53
阅读次数:
326
关于刷新TabelView的方法1、尽量不要用[self.tableView
reloadData];因为这个会全部刷新,会很费资源,只需要刷新需要刷新的某行或者多行就行了代码: // 刷新指定行 NSIndexPath *path =
[NSIndexPath indexPathForRow...
分类:
其他好文 时间:
2014-06-07 03:42:59
阅读次数:
199
方法一:-(void) viewDidLoad{[self
performSelectorInBackground:@selector(call1) withObject:nil];}-(void)
call1{timer1 = [NSTimer scheduledTimerWithTimeInte...
分类:
其他好文 时间:
2014-06-04 20:23:05
阅读次数:
228
1.当导入第三方库出现不支持ARC模式,可以在项目-》Build
Phases中对第三方类文件添加Compiler Flags(-fno-objc-arc)2.获取UITableViewCell中所有子控件//
获取当前tableView中的所有cellNSArray *array = [self....
分类:
移动开发 时间:
2014-06-04 19:04:15
阅读次数:
239
在多线程中使用定时器必须开启Runloop,因为只有开启Runloop保持现成为活动状态,才能保持定时器不断执行- (void)viewDidLoad{
[super viewDidLoad]; [self performSelectorInBackground:@selecto...
分类:
编程语言 时间:
2014-05-31 16:59:33
阅读次数:
285
比如:[bt addTarget:self
action:@selector(shareButtonClickHandler:) …… 后面未写完一开始我没加,就报错。
分类:
其他好文 时间:
2014-05-30 21:31:40
阅读次数:
219
使用iframe、弹出子页面刷新父页面iframeparent.location.reload();弹出子页面window.opener.location.reload();--这个方法是我尝试过的,可以成功实现我想要的功能,其他的没有尝试,不能保证绝对的正确.子窗口刷新父窗口self.window...
分类:
Web程序 时间:
2014-05-30 20:23:05
阅读次数:
302
A :父级调用子级页面 ,非IFRAME情况,类似平级:
window.open("子页面.html", "", "width=1024,height=768"); window.opener.子页面函数名字();B
: 父级调用子级页面 ,IFRAME情况 window.frames["ifram...
分类:
Web程序 时间:
2014-05-30 18:18:47
阅读次数:
271
The tricky thing is how to decide the key for a
hashmap. Especially when you intend to use self-defined objects as key.The
simple rule is you have to ...
分类:
编程语言 时间:
2014-05-29 09:08:40
阅读次数:
362
- (IBAction)leftRotate { // 1.取得头像按钮 UIButton *head
= (UIButton *)[self.view viewWithTag:10]; // 2.向左旋转45° // 45 180 // 角度是正数:顺时针,
角度是负数:逆时针// ...
分类:
其他好文 时间:
2014-05-28 13:36:43
阅读次数:
237