路径:NSString *parh = [[NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES) firstObject] stringByAppendingPathComponent:@"searchHistory.plist"];
获取:NSMutableArray *searchHistories = [NSKeyedUnarchiver unarchiveObjectWithFile:parh];
插入某条:[searchHistories removeObject:@"historyText"];
[searchHistories insertObject:@"historyText" atIndex:0];
[NSKeyedArchiver archiveRootObject:searchHistories toFile:parh];
删除某条:[searchHistories removeObject:@"historyText"];
[NSKeyedArchiver archiveRootObject:searchHistories toFile:parh];
清空:[searchHistories removeAllObjects];
[NSKeyedArchiver archiveRootObject:searchHistories toFile:parh];