ios objective c tableview delegate method
- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath{
//셀 선택시 실행될 메서드
}
-(CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath{
//셀 높이 설정
}
- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section{
//셀 갯수 설정
}
//
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath{
//custom cell define
NSString *CellIdentifier = [NSString stringWithFormat:@"S%dR%da",(int)indexPath.section,(int)indexPath.row];
//셀 구분자 설정
RankListTableViewCell *cell = (RankListTableViewCell*)[tableView dequeueReusableCellWithIdentifier:CellIdentifier];
if(cell == nil){
cell = [[RankListTableViewCell alloc]initWithStyle:UITableViewCellStyleDefault reuseIdentifier:CellIdentifier];
//cell 컨텐츠 설정
}
return cell;
}