//首先cell方法
- (UITableViewCell*)tableView:(UITableView*)tableView cellForRowAtIndexPath:(NSIndexPath*)indexPath
{
? ? //cell復(fù)用,唯一標(biāo)識
? ? staticNSString*identifier =@"Cell";
? ? //先在緩存池中取
? ? UITableViewCell*cell = [tableViewdequeueReusableCellWithIdentifier:identifier];
? ? //緩存池中沒有再創(chuàng)建屠升,并添加標(biāo)識潮改,cell移出屏幕時(shí)放入緩存池以復(fù)用
? ? if(cell ==nil) {
? ? ? ? cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:identifier];
}
? ? returncell;
}