- (void) networkReachabilityDidUpdate:(NetworkReachability*)reachability
{
[NSObject cancelPreviousPerformRequestsWithTarget:self selector:@selector(reachabilityChanged) object:nil];
...
分类:
其他好文 时间:
2014-05-13 08:17:19
阅读次数:
219
self.isOpen = [NSMutableArray array];
for (int j = 0; j
[self.isOpen addObject:[NSNumber numberWithInt:0]];
}
-(void)buttonClick:(UIButton*)button
{
NSNumber *num ...
分类:
其他好文 时间:
2014-05-13 08:12:11
阅读次数:
264
1、定义C函数:
void dynamicMethodIMP(id
self, SEL _cmd)
{
NSLog(@"蜗牛也疯狂");
}
2、重写函数+(BOOL)resolveInstanceMethod:(SEL)sel
+(BOOL)resolveInstanceMethod:(SEL)sel
{
class_addMethod([self
...
分类:
移动开发 时间:
2014-05-13 08:09:05
阅读次数:
412
显示注册用户的前台主要代码如下:
{%block content%}
{%for i in users%}
{{i[1]}}({{i[3]}}星级)
{%end%}
{%end%}
显示注册用户的后台代码如下:
class memberHandler(tornado.web.RequestHandler):
def get(self):
name=self.get_coo...
分类:
其他好文 时间:
2014-05-12 23:10:06
阅读次数:
574
Given two numbers represented as strings,
return multiplication of the numbers as a string.Note: The numbers can be
arbitrarily large and are non-nega...
分类:
其他好文 时间:
2014-05-11 14:35:13
阅读次数:
270
self指针:self是oc面向对象设计中的一个特殊指针,相当于java中的this,但是比this强大,this只能访问实例对象的相关方法和成员变量,或者说this只代表实例对象;self不仅可以代表实例对象,还可以代表类对象;谁调用当前方法,self就代表谁;如果self用在了以"-"号的方法中...
分类:
其他好文 时间:
2014-05-10 07:00:03
阅读次数:
622
import time
import SimpleHTTPServer
import SocketServer
BYTES_PER_SECOND=160*1024
class MyHTTPRequestHandler(SimpleHTTPServer.SimpleHTTPRequestHandler):
def do_GET(self):
"""Serve a GET re...
分类:
其他好文 时间:
2014-05-10 03:36:34
阅读次数:
276
tableView 实现的方法 无分组的cell
#pragma mark - Table view data source
- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
{
return self.contacts.count;
}
- (UITable...
分类:
移动开发 时间:
2014-05-09 21:03:32
阅读次数:
424
Georgia and BobTime Limit:1000MSMemory
Limit:10000KTotal Submissions:7233Accepted:2173DescriptionGeorgia and Bob decide
to play a self-invented game. ...
分类:
其他好文 时间:
2014-05-09 20:27:36
阅读次数:
374
addTarget:self 的意思是说,这个方法在本类中也可以传入其他类的指针*/
分类:
其他好文 时间:
2014-05-09 19:55:49
阅读次数:
236