.plist

 NSString *path = nil;spa

    path = [[NSBundle mainBundle] pathForResource:@"AreaBBSPlist" ofType:@"plist"];3d

    NSArray *pathArray = [NSArray arrayWithContentsOfFile:path];orm

    for (int i='A'; i<='Z'; i++) {string

        NSMutableArray *arr = [[NSMutableArray alloc] init];it

        for (NSDictionary *dict in pathArray) {io

            if ([[dict objectForKey:@"firstletter"] isEqualToString:[NSString stringWithFormat:@"%c",i]]) {table

                [arr addObject:dict];object

            }stl

        }margin

        if (arr.count) {

            [_dataArray addObject:arr];

        }

        [arr release];

    }

    // Do any additional setup after loading the view.

}

相關文章
相關標籤/搜索