{"id":191472,"date":"2013-08-26T21:02:03","date_gmt":"2013-08-26T17:02:03","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=191472"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=191472","title":{"rendered":"<span class=\"post_title\">Pro Core Data for iOS. \u0413\u043b\u0430\u0432\u0430 \u21161. \u041f\u0440\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u0430\u044f \u0447\u0430\u0441\u0442\u044c<\/span>"},"content":{"rendered":"<div class=\"content html_format\">   \t\u0425\u0430\u0431\u0440\u0430\u043b\u044e\u0434\u0438, \u0434\u043e\u0431\u0440\u044b\u0439 \u0434\u0435\u043d\u044c!<br \/>  \u0421\u0435\u0433\u043e\u0434\u043d\u044f \u0445\u043e\u0447\u0443 \u043d\u0430\u0447\u0430\u0442\u044c <b>\u0432\u043e\u043b\u044c\u043d\u044b\u0439<\/b> \u043f\u0435\u0440\u0435\u0432\u043e\u0434 \u043a\u043d\u0438\u0433\u0438 \u041c\u0438\u0445\u0430\u0435\u043b\u044f \u041f\u0440\u0438\u0432\u0430\u0442\u0430 \u0438 \u0420\u043e\u0431\u0435\u0440\u0442\u0430 \u0412\u0430\u0440\u043d\u0435\u0440\u0430 \u00abPro Core Data for iOS\u00bb, \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u043c\u043e\u0436\u0435\u0442\u0435 \u0441\u043a\u0430\u0447\u0430\u0442\u044c \u043f\u043e <a href=\"http:\/\/it-ebooks.info\/book\/1843\/\">\u044d\u0442\u043e\u0439<\/a> \u0441\u0441\u044b\u043b\u043a\u0435. \u041a\u0430\u0436\u0434\u0430\u044f \u0433\u043b\u0430\u0432\u0430 \u0431\u0443\u0434\u0435\u0442 \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0442\u044c \u0442\u0435\u043e\u0440\u0435\u0442\u0438\u0447\u0435\u0441\u043a\u0443\u044e \u0438 <b>\u043f\u0440\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u0443\u044e<\/b> \u0447\u0430\u0441\u0442\u044c.<\/p>\n<p>  <img decoding=\"async\" src=\"http:\/\/habr.habrastorage.org\/post_images\/884\/2d0\/182\/8842d018201f3945800282b64f1d7221.jpg\" alt=\"image\"\/><\/p>\n<p>  \u0421\u043e\u0434\u0435\u0440\u0436\u0430\u043d\u0438\u0435:  <\/p>\n<ul>\n<li> <a href=\"http:\/\/habrahabr.ru\/post\/191334\/\">\u0413\u043b\u0430\u0432\u0430 \u21161. \u041f\u0440\u0438\u0441\u0442\u0443\u043f\u0430\u0435\u043c<\/a> (\u041f\u0440\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u0430\u044f \u0447\u0430\u0441\u0442\u044c) <\/li>\n<li> \u0413\u043b\u0430\u0432\u0430 \u21162. \u0423\u0441\u0432\u0430\u0438\u0432\u0430\u0435\u043c Core Data<\/li>\n<li> \u0413\u043b\u0430\u0432\u0430 \u21163. \u0425\u0440\u0430\u043d\u0435\u043d\u0438\u0435 \u0434\u0430\u043d\u043d\u044b\u0445: SQLite \u0438 \u0434\u0440\u0443\u0433\u0438\u0435 \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u044b<\/li>\n<li> \u0413\u043b\u0430\u0432\u0430 \u21164. \u0421\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u043c\u043e\u0434\u0435\u043b\u0438 \u0434\u0430\u043d\u043d\u044b\u0445<\/li>\n<li> \u0413\u043b\u0430\u0432\u0430 \u21165. \u0420\u0430\u0431\u043e\u0442\u0430\u0435\u043c \u0441 \u043e\u0431\u044a\u0435\u043a\u0442\u0430\u043c\u0438 \u0434\u0430\u043d\u043d\u044b\u0445<\/li>\n<li> \u0413\u043b\u0430\u0432\u0430 \u21166. \u041e\u0431\u0440\u0430\u0431\u043e\u0442\u043a\u0430 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0438\u0440\u0443\u044e\u0449\u0438\u0445 \u043c\u043d\u043e\u0436\u0435\u0441\u0442\u0432<\/li>\n<li> \u0413\u043b\u0430\u0432\u0430 \u21167. \u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u0438 \u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u043e\u0439 \u043f\u0430\u043c\u044f\u0442\u0438<\/li>\n<li> \u0413\u043b\u0430\u0432\u0430 \u21168. \u0423\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0432\u0435\u0440\u0441\u0438\u044f\u043c\u0438 \u0438 \u043c\u0438\u0433\u0440\u0430\u0446\u0438\u0438<\/li>\n<li> \u0413\u043b\u0430\u0432\u0430 \u21169. \u0423\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0442\u0430\u0431\u043b\u0438\u0446\u0430\u043c\u0438 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c NSFetchedResultsController<\/li>\n<li> \u0413\u043b\u0430\u0432\u0430 \u211610. \u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 Core Data \u0432 \u043f\u0440\u043e\u0434\u0432\u0438\u043d\u0443\u0442\u044b\u0445 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f\u0445<\/li>\n<\/ul>\n<p>  <a name=\"habracut\"><\/a><\/p>\n<h4>\u041f\u0440\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u0430\u044f \u0447\u0430\u0441\u0442\u044c<\/h4>\n<p>  \u0422\u0430\u043a \u043a\u0430\u043a \u044d\u0442\u043e \u043f\u0435\u0440\u0432\u0430\u044f \u0433\u043b\u0430\u0432\u0430 \u0438 \u0435\u0451 \u043c\u043e\u0436\u043d\u043e \u0441\u0447\u0438\u0442\u0430\u0442\u044c \u0432\u0432\u043e\u0434\u043d\u043e\u0439, \u0442\u043e \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u043f\u0440\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u0437\u0430\u0434\u0430\u043d\u0438\u044f \u043c\u044b \u0432\u044b\u0431\u0435\u0440\u0435\u043c \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u043e\u0431\u044b\u0447\u043d\u043e\u0433\u043e \u0441\u043e\u0446\u0438\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u0431\u0443\u0434\u0435\u0442 \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0442\u044c \u0441\u043f\u0438\u0441\u043e\u043a \u043d\u0430\u0448\u0438\u0445 \u0434\u0440\u0443\u0437\u0435\u0439 \u0438\u0437 \u0412\u041a \u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c Core Data \u0434\u043b\u044f \u0445\u0440\u0430\u043d\u0435\u043d\u0438\u044f \u0434\u0430\u043d\u043d\u044b\u0445 \u043e \u043d\u0438\u0445.<br \/>  \u041f\u0440\u0438\u043c\u0435\u0440\u043d\u043e (\u0432 \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0435 \u0440\u0435\u0448\u0438\u043c \u0447\u0442\u043e \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c\/\u0438\u0441\u043a\u043b\u044e\u0447\u0438\u0442\u044c) \u0442\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u0433\u043b\u044f\u0434\u0435\u0442\u044c \u043d\u0430\u0448\u0435 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u043f\u043e\u0441\u043b\u0435 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u0438\u0445 \u0447\u0430\u0441\u043e\u0432 (\u0430 \u043c\u043e\u0436\u0435\u0442 \u0438 \u043c\u0438\u043d\u0443\u0442) \u0443\u043f\u043e\u0440\u043d\u043e\u0433\u043e \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f:  <\/p>\n<table>\n<tr>\n<td><img decoding=\"async\" src=\"https:\/\/github-camo.global.ssl.fastly.net\/765e9e34ccf97ff4c41771a88c56b8c00eda9a45\/687474703a2f2f686162726173746f726167652e6f72672f73746f72616765322f6134332f3631642f3732642f61343336316437326439346431313033333264393130646162656364636364662e706e67\" alt=\"image\"\/>  <\/td>\n<td><img decoding=\"async\" src=\"https:\/\/github-camo.global.ssl.fastly.net\/b09c4df5b98f706063370d91ad6c8ba3748e7f6e\/687474703a2f2f686162726173746f726167652e6f72672f73746f72616765322f3539372f3434342f6535352f35393734343465353538386362376461336263303862646133303230323830612e706e67\" alt=\"image\"\/>  <\/td>\n<\/tr>\n<\/table>\n<p>  \u041a\u0430\u043a \u0412\u044b \u043c\u043e\u0433\u043b\u0438 \u0443\u0436\u0435 \u0434\u043e\u0433\u0430\u0434\u0430\u0442\u044c\u0441\u044f, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043c\u044b \u0431\u0443\u0434\u0435\u043c <a href=\"https:\/\/github.com\/AndrewShmig\/Vkontakte-iOS-SDK-v2.0\">Vkontakte iOS SDK v2.0<\/a>.<br \/>  \u041a\u0441\u0442\u0430\u0442\u0438, \u043f\u0440\u043e\u0448\u0443 \u043c\u0435\u043d\u044f \u043f\u0440\u043e\u0441\u0442\u0438\u0442\u044c \u0437\u0430 \u0442\u043e, \u0447\u0442\u043e \u0432 \u043f\u0440\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0439 \u0447\u0430\u0441\u0442\u0438 \u0431\u0443\u0434\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u043d\u0435 \u0442\u043e\u043b\u044c\u043a\u043e XCode, \u043d\u043e \u0438 <a href=\"https:\/\/www.jetbrains.com\/objc\/\">AppCode<\/a> (\u0440\u0435\u0431\u044f\u0442\u0430\u043c \u0438\u0437 JB \u0441\u043f\u0430\u0441\u0438\u0431\u043e \u0437\u0430 \u043f\u0440\u043e\u0434\u0443\u043a\u0442!). \u0412\u0441\u0451, \u0447\u0442\u043e \u043c\u043e\u0436\u043d\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0432 AppCode, \u0431\u0443\u0434\u0435\u0442 \u0442\u0430\u043c \u0441\u0434\u0435\u043b\u0430\u043d\u043e.<\/p>\n<p>  \u041f\u043e\u0435\u0445\u0430\u043b\u0438\u2026<\/p>\n<h5>\u0421\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u043f\u0443\u0441\u0442\u043e\u0433\u043e \u043f\u0440\u043e\u0435\u043a\u0442\u0430<\/h5>\n<p>  \u0421\u043e\u0437\u0434\u0430\u0434\u0438\u043c \u043f\u0443\u0441\u0442\u043e\u0439 \u043f\u0440\u043e\u0435\u043a\u0442 \u0431\u0435\u0437 Core Data \u2014 Single View Application.<br \/>  <img decoding=\"async\" src=\"http:\/\/s1.ipicture.ru\/uploads\/20130826\/ni3t3rRw.png\" alt=\"image\"\/><br \/>  <img decoding=\"async\" src=\"http:\/\/s1.ipicture.ru\/uploads\/20130826\/frg7bKal.png\" alt=\"image\"\/><\/p>\n<p>  \u041f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u0443\u0434\u0430\u0447\u043d\u043e \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u043b\u043e\u0441\u044c:<br \/>  <img decoding=\"async\" src=\"http:\/\/s1.ipicture.ru\/uploads\/20130826\/5VN4jhmi.png\" alt=\"image\"\/><\/p>\n<h5>\u0414\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0438 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 UITableView<\/h5>\n<p>  \u041e\u0442\u043a\u0440\u044b\u0432\u0430\u0435\u043c ASAViewController.h \u0438 \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0435 \u0441\u0432\u043e\u0439\u0441\u0442\u0432\u043e:  <\/p>\n<pre><code class=\"objectivec\">@property (nonatomic, strong) UITableView *tableView; <\/code><\/pre>\n<p>  \u041f\u043e\u043b\u043d\u044b\u0439 \u0432\u0438\u0434 ASAViewController.h:  <\/p>\n<pre><code class=\"objectivec\">#import &lt;UIKit\/UIKit.h&gt;  @interface ASAViewController : UIViewController  @property (nonatomic, strong) UITableView *tableView;  @end <\/code><\/pre>\n<p>  \u041e\u0442\u043a\u0440\u044b\u0432\u0430\u0435\u043c ASAViewController.m \u0438 \u0432 \u043c\u0435\u0442\u043e\u0434 viewDidLoad \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c \u0441\u0442\u0440\u043e\u043a\u0438 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f \u0442\u0430\u0431\u043b\u0438\u0446\u044b UITableView:  <\/p>\n<pre><code class=\"objectivec\">    CGRect frame = [[UIScreen mainScreen] bounds];     _tableView = [[UITableView alloc]                                initWithFrame:frame                                        style:UITableViewStylePlain];     [self.view addSubview:_tableView]; <\/code><\/pre>\n<p>  \u041f\u043e\u043b\u043d\u044b\u0439 \u0432\u0438\u0434 ASAViewController.m:  <\/p>\n<pre><code class=\"objectivec\">#import &quot;ASAViewController.h&quot;  @implementation ASAViewController  - (void)viewDidLoad {     CGRect frame = [[UIScreen mainScreen] bounds];     _tableView = [[UITableView alloc]                                initWithFrame:frame                                        style:UITableViewStylePlain];     [_tableView setDelegate:self];     [_tableView setDataSource:self];     [self.view addSubview:_tableView]; }  @end <\/code><\/pre>\n<p>  \u0417\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u043c:<br \/>  <img decoding=\"async\" src=\"http:\/\/s1.ipicture.ru\/uploads\/20130826\/7Du7NLJx.png\" alt=\"image\"\/><\/p>\n<p>  \u041e\u0441\u0442\u0430\u043b\u043e\u0441\u044c \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u0442\u044c \u043c\u0435\u0442\u043e\u0434\u044b \u0434\u0435\u043b\u0435\u0433\u0430\u0442\u043e\u0432 UITableViewDelegate \u0438 UITableViewDataSource.<br \/>  \u0414\u043e\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u043c \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b\u044b \u0432 \u00a0ASAViewController.h:  <\/p>\n<pre><code class=\"objectivec\">@interface ASAViewController : UIViewController &lt;UITableViewDataSource, UITableViewDelegate&gt; <\/code><\/pre>\n<p>  \u041e\u0442\u043a\u0440\u044b\u0432\u0430\u0435\u043c ASAViewController.m \u0438 \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u044b\u0432\u0430\u0435\u043c \u0434\u0432\u0430 \u043c\u0435\u0442\u043e\u0434\u0430 (\u043e\u0434\u0438\u043d \u0434\u043b\u044f \u0432\u043e\u0437\u0432\u0440\u0430\u0442\u0430 \u043a\u043e\u043b-\u0432\u0430 \u0434\u0440\u0443\u0437\u0435\u0439 \u0432 \u0441\u043f\u0438\u0441\u043a\u0435, \u0430 \u0432\u0442\u043e\u0440\u043e\u0439 \u0434\u043b\u044f \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f \u0437\u0430\u043f\u043e\u043b\u043d\u0435\u043d\u043d\u043e\u0439 \u044f\u0447\u0435\u0439\u043a\u0438 \u0441 \u0434\u0430\u043d\u043d\u044b\u043c\u0438 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f):  <\/p>\n<pre><code class=\"objectivec\">#pragma mark - UITableViewDelegate & UITableViewDataSource  - (NSInteger)tableView:(UITableView *)tableView   numberOfRowsInSection:(NSInteger)section {     return [_userFriends count]; }  - (UITableViewCell *)tableView:(UITableView *)tableView   cellForRowAtIndexPath:(NSIndexPath *)indexPath {     static NSString *cellID = @&quot;friendID&quot;;      UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:cellID];     if(nil == cell){         cell = [[UITableViewCell alloc]                 initWithStyle:UITableViewCellStyleSubtitle               reuseIdentifier:cellID];     }      \/\/    setting default image while main photo is loading     cell.imageView.image = [UIImage imageNamed:@&quot;default.png&quot;];      dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_BACKGROUND, 0), ^{         NSString* imgPath = _userFriends[(NSUInteger)indexPath.row][@&quot;photo&quot;];         NSData* img = [NSData dataWithContentsOfURL:[NSURL URLWithString:imgPath]];          dispatch_async(dispatch_get_main_queue(), ^{             cell.imageView.image = [UIImage imageWithData:img];         });     });      NSString* firstName = _userFriends[(NSUInteger)indexPath.row][@&quot;first_name&quot;];     NSString* lastName = _userFriends[(NSUInteger)indexPath.row][@&quot;last_name&quot;];     NSString* fullName = [NSString stringWithFormat:@&quot;%@ %@&quot;, firstName, lastName];     cell.textLabel.text = fullName;      NSString* status = _userFriends[(NSUInteger)indexPath.row][@&quot;status&quot;];     cell.detailTextLabel.text = status;      return cell; } <\/code><\/pre>\n<p>  \u041f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u0430\u044f _userFriends \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0441\u0432\u043e\u0439\u0441\u0442\u0432\u043e\u043c ASAViewController:  <\/p>\n<pre><code class=\"objectivec\">@property (nonatomic, strong) NSMutableArray *userFriends; <\/code><\/pre>\n<p>  \u0418\u0442\u043e\u0433\u043e\u0432\u044b\u0439 \u0432\u0438\u0434 ASAViewController.h \u0438 ASAViewController.m:  <\/p>\n<pre><code class=\"objectivec\">#import &lt;UIKit\/UIKit.h&gt;  @interface ASAViewController : UIViewController &lt;UITableViewDataSource, UITableViewDelegate&gt;  @property (nonatomic, strong) UITableView *tableView; @property (nonatomic, strong) NSMutableArray *userFriends;  @end <\/code><\/pre>\n<p>  <\/p>\n<pre><code class=\"objectivec\">#import &quot;ASAViewController.h&quot;  @implementation ASAViewController  - (void)viewDidLoad {     _userFriends = [[NSMutableArray alloc] init];      CGRect frame = [[UIScreen mainScreen] bounds];     _tableView = [[UITableView alloc]                                initWithFrame:frame                                        style:UITableViewStylePlain];     [_tableView setDelegate:self];     [_tableView setDataSource:self];     [self.view addSubview:_tableView]; }  #pragma mark - UITableViewDelegate & UITableViewDataSource  - (NSInteger)tableView:(UITableView *)tableView   numberOfRowsInSection:(NSInteger)section {     return [_userFriends count]; }  - (UITableViewCell *)tableView:(UITableView *)tableView   cellForRowAtIndexPath:(NSIndexPath *)indexPath {     static NSString *cellID = @&quot;friendID&quot;;      UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:cellID];     if(nil == cell){         cell = [[UITableViewCell alloc]                 initWithStyle:UITableViewCellStyleSubtitle               reuseIdentifier:cellID];     }      \/\/    setting default image while main photo is loading     cell.imageView.image = [UIImage imageNamed:@&quot;default.png&quot;];      dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_BACKGROUND, 0), ^{         NSString* imgPath = _userFriends[(NSUInteger)indexPath.row][@&quot;photo&quot;];         NSData* img = [NSData dataWithContentsOfURL:[NSURL URLWithString:imgPath]];          dispatch_async(dispatch_get_main_queue(), ^{             cell.imageView.image = [UIImage imageWithData:img];         });     });      NSString* firstName = _userFriends[(NSUInteger)indexPath.row][@&quot;first_name&quot;];     NSString* lastName = _userFriends[(NSUInteger)indexPath.row][@&quot;last_name&quot;];     NSString* fullName = [NSString stringWithFormat:@&quot;%@ %@&quot;, firstName, lastName];     cell.textLabel.text = fullName;      NSString* status = _userFriends[(NSUInteger)indexPath.row][@&quot;status&quot;];     cell.detailTextLabel.text = status;      return cell; }  @end <\/code><\/pre>\n<p>  \u0412\u0441\u0451 \u0434\u043e\u043b\u0436\u043d\u043e \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c\u0441\u044f \u043d\u0430 \u0443\u0440\u0430. \u041f\u0435\u0440\u0435\u0445\u043e\u0434\u0438\u043c \u043a \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u043c\u0443 \u0448\u0430\u0433\u0443.<\/p>\n<h5>\u0418\u043d\u0442\u0435\u0433\u0440\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0412\u041a\u043e\u043d\u0442\u0430\u043a\u0442\u0435 iOS SDK v2.0<\/h5>\n<p>  \u0417\u0430\u0431\u0438\u0440\u0430\u0435\u043c \u0438\u0441\u0445\u043e\u0434\u043d\u0438\u043a\u0438 \u043f\u043e <a href=\"https:\/\/github.com\/AndrewShmig\/Vkontakte-iOS-SDK-v2.0\">\u044d\u0442\u043e\u0439<\/a> \u0441\u0441\u044b\u043b\u043a\u0435.<\/p>\n<p>  \u041f\u043e\u0434\u043a\u043b\u044e\u0447\u0430\u0435\u043c QuartzCore.framework<br \/>  <img decoding=\"async\" src=\"https:\/\/github-camo.global.ssl.fastly.net\/f6027a27a281599c42623a4ba51c0fe788cd214f\/687474703a2f2f73322e69706963747572652e72752f75706c6f6164732f32303133303731342f3134456a565365512e706e67\" alt=\"image\"\/><\/p>\n<p>  \u0414\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c Vkontakte iOS SDK<br \/>  <img decoding=\"async\" src=\"https:\/\/github-camo.global.ssl.fastly.net\/8c059d2f4782669fc4e4ede83b95bfb2dc9c6645\/687474703a2f2f73322e69706963747572652e72752f75706c6f6164732f32303133303731342f4737554b745875652e706e67\" alt=\"image\"\/><\/p>\n<p>  \u0412 ASAAppDelegate.h \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c \u0434\u0432\u0430 \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b\u0430:  <\/p>\n<pre><code class=\"objectivec\">@interface ASAAppDelegate : UIResponder &lt;UIApplicationDelegate, VKConnectorDelegate, VKRequestDelegate&gt; <\/code><\/pre>\n<p>  \u041e\u0442\u043a\u0440\u044b\u0432\u0430\u0435\u043c \u0444\u0430\u0439\u043b \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 ASAAppDelegate.m \u0438 \u0432\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u043c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435 \u0441\u0442\u0440\u043e\u043a\u0438 \u0432 \u043c\u0435\u0442\u043e\u0434 <code>- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions<\/code>:  <\/p>\n<pre><code class=\"objectivec\">    [[VKConnector sharedInstance]                   setDelegate:self];     [[VKConnector sharedInstance] startWithAppID:@&quot;3541027&quot;                                       permissons:@[@&quot;friends&quot;]]; <\/code><\/pre>\n<p>  \u0414\u0430\u043d\u043d\u044b\u0439 \u043a\u043e\u0434 \u043f\u0440\u0438 \u0437\u0430\u043f\u0443\u0441\u043a\u0435 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u043f\u043e\u043a\u0430\u0436\u0435\u0442 \u0432\u0441\u043f\u043b\u044b\u0432\u0430\u044e\u0449\u0435\u0435 \u043e\u043a\u043d\u043e \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044e \u0434\u043b\u044f \u0430\u0432\u0442\u043e\u0440\u0438\u0437\u0430\u0446\u0438\u0438 \u0432 \u0441\u043e\u0446\u0438\u0430\u043b\u044c\u043d\u043e\u0439 \u0441\u0435\u0442\u0438 \u0412\u041a\u043e\u043d\u0442\u0430\u043a\u0442\u0435.<br \/>  <img decoding=\"async\" src=\"http:\/\/s1.ipicture.ru\/uploads\/20130826\/e1wOUTsf.png\" alt=\"image\"\/><\/p>\n<p>  \u0412 \u00a0ASAAppDelegate.m \u0440\u0435\u0430\u043b\u0438\u0437\u0443\u0435\u043c \u0435\u0449\u0435 \u0434\u0432\u0430 \u043c\u0435\u0442\u043e\u0434\u0430:  <\/p>\n<pre><code class=\"objectivec\">#pragma mark - VKConnectorDelegate  - (void)        VKConnector:(VKConnector *)connector accessTokenRenewalSucceeded:(VKAccessToken *)accessToken { \/\/   now we can make request     [[VKUser currentUser] setDelegate:self];     [[VKUser currentUser] friendsGet:@{             @&quot;uid&quot;    : @([VKUser currentUser].accessToken.userID),             @&quot;fields&quot; : @&quot;first_name,last_name,photo,status&quot;     }]; }  #pragma mark - VKRequestDelegate  - (void)VKRequest:(VKRequest *)request          response:(id)response {     ASAViewController *controller = (ASAViewController *)self.window.rootViewController;      controller.userFriends = response[@&quot;response&quot;];     [controller.tableView reloadData]; } <\/code><\/pre>\n<p>  \u041e\u043a\u043e\u043d\u0447\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u0439 \u0432\u0438\u0434 ASAAppDelegate.h \u0438 ASAAppDelegate.m \u043d\u0430 \u0434\u0430\u043d\u043d\u043e\u043c \u044d\u0442\u0430\u043f\u0435:  <\/p>\n<pre><code class=\"objectivec\">#import &lt;UIKit\/UIKit.h&gt; #import &quot;VKConnector.h&quot; #import &quot;VKRequest.h&quot;  @class ASAViewController;  @interface ASAAppDelegate : UIResponder &lt;UIApplicationDelegate, VKConnectorDelegate, VKRequestDelegate&gt;  @property (strong, nonatomic) UIWindow *window; @property (strong, nonatomic) ASAViewController *viewController;  @end <\/code><\/pre>\n<p>  <\/p>\n<pre><code class=\"objectivec\">#import &quot;ASAAppDelegate.h&quot; #import &quot;ASAViewController.h&quot; #import &quot;VKUser.h&quot; #import &quot;VKAccessToken.h&quot;   @implementation ASAAppDelegate  - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {     self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];      \/\/ Override point for customization after application launch.     self.viewController = [[ASAViewController alloc] initWithNibName:@&quot;ASAViewController&quot; bundle:nil];     self.window.rootViewController = self.viewController;     [self.window makeKeyAndVisible];      [[VKConnector sharedInstance]                   setDelegate:self];     [[VKConnector sharedInstance] startWithAppID:@&quot;3541027&quot;                                       permissons:@[@&quot;friends&quot;]];      return YES; }  #pragma mark - VKConnectorDelegate  - (void)        VKConnector:(VKConnector *)connector accessTokenRenewalSucceeded:(VKAccessToken *)accessToken { \/\/   now we can make request     [[VKUser currentUser] setDelegate:self];     [[VKUser currentUser] friendsGet:@{             @&quot;uid&quot;    : @([VKUser currentUser].accessToken.userID),             @&quot;fields&quot; : @&quot;first_name,last_name,photo,status&quot;     }]; }  #pragma mark - VKRequestDelegate  - (void)VKRequest:(VKRequest *)request          response:(id)response {     ASAViewController *controller = (ASAViewController *)self.window.rootViewController;      controller.userFriends = response[@&quot;response&quot;];     [controller.tableView reloadData]; }  @end <\/code><\/pre>\n<p>  \u0417\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u043c \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u0438 \u0432\u0438\u0434\u0438\u043c \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0435 (\u043d\u0435 \u0437\u0430\u0431\u044b\u0432\u0430\u0439\u0442\u0435, \u0447\u0442\u043e \u0432 \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u043e\u043c \u0432\u044b\u0448\u0435 \u043f\u0440\u0438\u043c\u0435\u0440\u0435 \u043d\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u043a\u044d\u0448\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0437\u0430\u043f\u0440\u043e\u0441\u043e\u0432 \u043d\u0430\u043c\u0435\u0440\u0435\u043d\u043d\u043e):<br \/>  <img decoding=\"async\" src=\"http:\/\/ipicture.ru\/uploads\/20130826\/cOMh7Yl1.png\" alt=\"image\"\/><br \/>  <img decoding=\"async\" src=\"http:\/\/ipicture.ru\/uploads\/20130826\/UWTsBrlC.png\" alt=\"image\"\/><\/p>\n<h5>\u0414\u0435\u0441\u0435\u0440\u0442 \u0438\u0437 Core Data<\/h5>\n<p>  \u0412\u043e\u0442 \u043c\u044b \u0438 \u043f\u043e\u0434\u043e\u0448\u043b\u0438 \u043a \u0441\u0430\u043c\u043e\u043c\u0443 \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u043e\u043c\u0443 \u0438 \u0443\u0432\u043b\u0435\u043a\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u043c\u0443! \u041d\u0430\u0434\u0435\u044e\u0441\u044c \u0412\u044b \u0435\u0449\u0435 \u043d\u0435 \u043f\u043e\u0442\u0435\u0440\u044f\u043b\u0438 \u0436\u0435\u043b\u0430\u043d\u0438\u0435 \u0434\u043e\u0434\u0435\u043b\u0430\u0442\u044c \u043f\u0440\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u0443\u044e \u0447\u0430\u0441\u0442\u044c \ud83d\ude09 \u041e\u0442\u0432\u043b\u0435\u043a\u0438\u0442\u0435\u0441\u044c, \u0432\u044b\u043f\u0435\u0439\u0442\u0435 \u0447\u0430\u0439\u043a\u0443 \u0441 \u0441\u0443\u0448\u043a\u0430\u043c\u0438, \u043f\u043e\u0433\u0440\u044b\u0437\u0438\u0442\u0435 \u043a\u043e\u043d\u0444\u0435\u0442\u043a\u0443, \u0440\u0430\u0437\u043e\u043c\u043d\u0438\u0442\u0435\u0441\u044c, \u043f\u043e\u0434\u0442\u044f\u043d\u0438\u0442\u0435\u0441\u044c.<\/p>\n<p>  \u0417\u0430\u0447\u0435\u043c \u043d\u0430\u043c \u0437\u0434\u0435\u0441\u044c Core Data? \u041c\u044b \u043f\u043e\u0441\u0442\u0443\u043f\u0438\u043c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c: \u043f\u0440\u0438 \u043f\u0435\u0440\u0432\u043e\u043c \u0437\u0430\u043f\u0440\u043e\u0441\u0435 \u043a \u0441\u0435\u0440\u0432\u0435\u0440\u0443 \u0412\u041a\u043e\u043d\u0442\u0430\u043a\u0442\u0435 \u043c\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u043c \u0441\u043f\u0438\u0441\u043e\u043a \u0434\u0440\u0443\u0437\u0435\u0439 \u0438 \u0437\u0430\u043f\u0440\u0430\u0448\u0438\u0432\u0430\u0435\u043c\u044b\u0435 \u043f\u043e\u043b\u044f (\u0441\u0442\u0430\u0442\u0443\u0441, \u0444\u043e\u0442\u043e\u0433\u0440\u0430\u0444\u0438\u044f, \u0438\u043c\u044f, \u0444\u0430\u043c\u0438\u043b\u0438\u044f), \u044d\u0442\u0443 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044e \u0441\u043e\u0445\u0440\u0430\u043d\u0438\u043c \u0432 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u043e\u043c \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044f Core Data, \u0430 \u043f\u043e\u0442\u043e\u043c \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u043c \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u0438 \u0432\u043e \u0432\u0440\u0435\u043c\u044f \u0437\u0430\u043f\u0440\u043e\u0441\u0430 \u043e\u0442\u043a\u043b\u044e\u0447\u0438\u043c \u0438\u043d\u0442\u0435\u0440\u043d\u0435\u0442 \u0438 \u0432\u044b\u0432\u0435\u0434\u0435\u043c \u0441\u043f\u0438\u0441\u043e\u043a \u0434\u0440\u0443\u0437\u0435\u0439 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0431\u044b\u043b\u0438 \u0441\u043e\u0445\u0440\u0430\u043d\u0435\u043d\u044b \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u043e \u0432\u043e \u0432\u0440\u0435\u043c\u044f \u043f\u0435\u0440\u0432\u043e\u0433\u043e \u0437\u0430\u043f\u0440\u043e\u0441\u0430. \u0418\u0434\u0451\u0442? \u0422\u043e\u0433\u0434\u0430 \u043f\u0440\u0438\u0441\u0442\u0443\u043f\u0438\u043c.<\/p>\n<p>  \u0414\u043b\u044f \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u043a\u0438 \u0444\u0430\u043a\u0442\u0430 \u043e\u0442\u0441\u0443\u0442\u0441\u0442\u0432\u0438\u044f \u0438\u043d\u0442\u0435\u0440\u043d\u0435\u0442 \u0441\u043e\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u044f \u043c\u044b \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u0441\u044f \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043c\u0435\u0442\u043e\u0434\u043e\u043c \u0438\u0437 \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b\u0430 VKRequestDelegate:  <\/p>\n<pre><code class=\"objectivec\">- (void)VKRequest:(VKRequest *)request         connectionErrorOccured:(NSError *)error { \/\/    TODO } <\/code><\/pre>\n<p>  \u0422\u0435\u043b\u043e \u043c\u0435\u0442\u043e\u0434\u0430 \u043c\u044b \u043d\u0430\u043f\u0438\u0448\u0435\u043c \u043d\u0435\u043c\u043d\u043e\u0433\u043e \u043f\u043e\u0437\u0436\u0435.<\/p>\n<p>  \u0410\u0445 \u0434\u0430, \u0441\u043e\u0432\u0441\u0435\u043c \u0437\u0430\u0431\u044b\u043b! \u041f\u043e\u0434\u043a\u043b\u044e\u0447\u0430\u0435\u043c \u00a0<code>CoreData.framework<\/code>.<br \/>  <img decoding=\"async\" src=\"http:\/\/s1.ipicture.ru\/uploads\/20130826\/dV5D4oaH.png\" alt=\"image\"\/><br \/>  \u0414\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c \u0442\u0440\u0438 \u043b\u044e\u0431\u0438\u043c\u044b\u0435 \u043d\u0430\u043c\u0438 \u0441\u0432\u043e\u0439\u0441\u0442\u0432\u0430 \u0432 ASAAppDelegate.h:  <\/p>\n<pre><code class=\"objectivec\">@property (nonatomic, strong) NSManagedObjectModel *managedObjectModel; @property (nonatomic, strong) NSPersistentStoreCoordinator *coordinator; @property (nonatomic, strong) NSManagedObjectContext *managedObjectContext; <\/code><\/pre>\n<p>  \u0422\u0435\u043f\u0435\u0440\u044c \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0438\u043c \u0432 ASAAppDelegate.m \u0434\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u0442\u044c \u044f\u0432\u043d\u044b\u0435 \u0433\u0435\u0442\u0442\u0435\u0440\u044b \u0434\u043b\u044f \u0432\u0441\u0435\u0445 \u0442\u0440\u0451\u0445 \u0441\u0432\u043e\u0439\u0441\u0442\u0432.<br \/>  Managed Object Model:  <\/p>\n<pre><code class=\"objectivec\">- (NSManagedObjectModel *)managedObjectModel {     if(nil != _managedObjectModel)         return _managedObjectModel;      _managedObjectModel = [NSManagedObjectModel mergedModelFromBundles:nil];          return _managedObjectModel; } <\/code><\/pre>\n<p>  Persistent Store Coordinator:  <\/p>\n<pre><code class=\"objectivec\">- (NSPersistentStoreCoordinator *)coordinator {     if(nil != _coordinator)         return _coordinator;      NSURL *storeURL = [[[[NSFileManager defaultManager]                                         URLsForDirectory:NSDocumentDirectory                                                inDomains:NSUserDomainMask]                                         lastObject]                                         URLByAppendingPathComponent:@&quot;BasicApplication.sqlite&quot;];      _coordinator = [[NSPersistentStoreCoordinator alloc]                                                   initWithManagedObjectModel:self.managedObjectModel];      NSError *error = nil;     if(![_coordinator addPersistentStoreWithType:NSSQLiteStoreType                                    configuration:nil                                              URL:storeURL                                          options:nil                                            error:&error]){         NSLog(@&quot;Unresolved error %@, %@&quot;, error, [error userInfo]);         abort();     }      return _coordinator; } <\/code><\/pre>\n<p>  Managed Object Context:  <\/p>\n<pre><code class=\"objectivec\">- (NSManagedObjectContext *)managedObjectContext {     if(nil != _managedObjectContext)         return _managedObjectContext;      NSPersistentStoreCoordinator *storeCoordinator = self.coordinator;      if(nil != storeCoordinator){         _managedObjectContext = [[NSManagedObjectContext alloc] init];         [_managedObjectContext setPersistentStoreCoordinator:storeCoordinator];     }      return _managedObjectContext; } <\/code><\/pre>\n<p>  Build\u2026 \u0418\u2026 \u0438\u2026 \u0432\u0441\u0451 \u043d\u043e\u0440\u043c\u0430\u043b\u044c\u043d\u043e. <\/p>\n<p>  \u0422\u0435\u043f\u0435\u0440\u044c \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0438\u043c \u043a \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044e \u043c\u043e\u0434\u0435\u043b\u0438. \u041a\u0441\u0442\u0430\u0442\u0438, \u0445\u043e\u0447\u0443 \u043e\u0442\u043c\u0435\u0442\u0438\u0442\u044c, \u0447\u0442\u043e \u044f \u0434\u0435\u043b\u0430\u044e \u0432\u0441\u0451 \u0431\u0435\u0437 \u0441\u0442\u0440\u0430\u0445\u043e\u0432\u043a\u0438 \u0438, \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u0432 \u043a\u043e\u043d\u0446\u0435 \u0447\u0442\u043e-\u0442\u043e \u0441 \u0447\u0435\u043c-\u0442\u043e \u0438 \u043d\u0435 \u0441\u043e\u0441\u0442\u044b\u043a\u0443\u0435\u0442\u0441\u044f, \u043d\u043e \u043c\u044b \u0436\u0435 \u0441\u043c\u0435\u043b\u044b\u0435 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0438\u0441\u0442\u044b!<br \/>  \u0414\u043b\u044f \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f \u043c\u043e\u0434\u0435\u043b\u0438 \u043d\u0430\u043c \u043f\u043e\u043d\u0430\u0434\u043e\u0431\u0438\u0442\u044c\u0441\u044f \u0442\u043e\u0442 \u0441\u0430\u043c\u044b\u0439 XCode.<br \/>  \u041e\u0442\u043a\u0440\u044b\u0432\u0430\u0435\u043c \u043d\u0430\u0448 \u043f\u0440\u043e\u0435\u043a\u0442 \u0432 \u043d\u0451\u043c, \u043d\u0430\u0436\u0438\u043c\u0430\u0435\u043c Control+N \u0438 \u0432\u044b\u0431\u0438\u0440\u0430\u0435\u043c Core Data -&gt; Data Model:<br \/>  <img decoding=\"async\" src=\"http:\/\/s1.ipicture.ru\/uploads\/20130826\/FIeaHU3P.png\" alt=\"image\"\/><\/p>\n<p>  \u0421\u043e\u0445\u0440\u0430\u043d\u0438\u043c \u043c\u043e\u0434\u0435\u043b\u044c \u043f\u043e\u0434 \u043d\u0430\u0437\u0432\u0430\u043d\u0438\u0435\u043c <b>Friend<\/b>:<br \/>  <img decoding=\"async\" src=\"http:\/\/s1.ipicture.ru\/uploads\/20130826\/jr98olAD.png\" alt=\"image\"\/><\/p>\n<p>  \u0412\u0438\u0434\u0438\u043c \u0443\u0436\u0435 \u0434\u043e\u0432\u043e\u043b\u044c\u043d\u043e \u0437\u043d\u0430\u043a\u043e\u043c\u044b\u0439 \u044d\u043a\u0440\u0430\u043d:<br \/>  <img decoding=\"async\" src=\"http:\/\/s1.ipicture.ru\/uploads\/20130826\/is6r12b5.png\" alt=\"image\"\/><\/p>\n<p>  \u0421\u043e\u0437\u0434\u0430\u0434\u0438\u043c \u043d\u043e\u0432\u0443\u044e \u0441\u0443\u0449\u043d\u043e\u0441\u0442\u044c \u043f\u043e\u0434 \u043d\u0430\u0437\u0432\u0430\u043d\u0438\u0435\u043c <b>Friend<\/b> \u0438 \u0434\u043e\u0431\u0430\u0432\u0438\u043c 4 \u0441\u0432\u043e\u0439\u0441\u0442\u0432\u0430: last_name (String), first_name (String), status (String), photo (Binary Data).<br \/>  <img decoding=\"async\" src=\"http:\/\/s1.ipicture.ru\/uploads\/20130826\/RVNh7EvU.png\" alt=\"image\"\/><\/p>\n<p>  \u0417\u0430\u0432\u0435\u0440\u0448\u0430\u0435\u043c \u0438 \u0437\u0430\u043a\u0440\u044b\u0432\u0430\u0435\u043c XCode.<\/p>\n<p>  \u0421\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0435, \u0447\u0442\u043e \u043c\u044b \u0434\u043e\u043b\u0436\u043d\u044b \u0441\u0434\u0435\u043b\u0430\u0442\u044c, \u0442\u0430\u043a \u044d\u0442\u043e \u0441\u043e\u0445\u0440\u0430\u043d\u0438\u0442\u044c \u0434\u0430\u043d\u043d\u044b\u0435 \u043e \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f\u0445 \u043f\u043e\u0441\u043b\u0435 \u043e\u0441\u0443\u0449\u0435\u0441\u0442\u0432\u043b\u0435\u043d\u0438\u044f \u0437\u0430\u043f\u0440\u043e\u0441\u0430. <br \/>  \u041e\u0442\u043a\u0440\u044b\u0432\u0430\u0435\u043c ASAAppDelegate.m, \u0441\u043f\u0443\u0441\u043a\u0430\u0435\u043c\u0441\u044f \u043a \u043c\u0435\u0442\u043e\u0434 VKRequest:response: \u0438 \u0438\u0437\u043c\u0435\u043d\u044f\u0435\u043c \u0435\u0433\u043e \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c:  <\/p>\n<pre><code class=\"objectivec\">- (void)VKRequest:(VKRequest *)request          response:(id)response {     ASAViewController *controller = (ASAViewController *)self.window.rootViewController;      controller.userFriends = response[@&quot;response&quot;];     [controller.tableView reloadData];  \/\/    \u0441\u043e\u0445\u0440\u0430\u043d\u044f\u0435\u043c \u0434\u0430\u043d\u043d\u044b\u0435 \u0432 \u0444\u043e\u043d\u0435, \u0447\u0442\u043e\u0431\u044b \u043d\u0435 \u0437\u0430\u043c\u043e\u0440\u0430\u0436\u0438\u0432\u0430\u0442\u044c \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441     dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_BACKGROUND, 0), ^{         for(NSDictionary *user in controller.userFriends){             NSManagedObject *friend = [NSEntityDescription insertNewObjectForEntityForName:@&quot;Friend&quot;                                                                     inManagedObjectContext:self.managedObjectContext];              [friend setValue:user[@&quot;first_name&quot;] forKey:@&quot;first_name&quot;];             [friend setValue:user[@&quot;last_name&quot;] forKey:@&quot;last_name&quot;];             [friend setValue:[NSData dataWithContentsOfURL:[NSURL URLWithString:user[@&quot;photo&quot;]]] forKey:@&quot;photo&quot;];             [friend setValue:user[@&quot;status&quot;] forKey:@&quot;status&quot;];              NSLog(@&quot;friend: %@&quot;, friend);         }          if([self.managedObjectContext hasChanges] && ![self.managedObjectContext save:nil]){             NSLog(@&quot;Unresolved error!&quot;);             abort();         }     }); } <\/code><\/pre>\n<p>  \u041d\u0430 \u043a\u0430\u0436\u0434\u043e\u0439 \u0438\u0442\u0435\u0440\u0430\u0446\u0438\u0438 \u043c\u044b \u0441\u043e\u0437\u0434\u0430\u0451\u043c \u043d\u043e\u0432\u044b\u0439 \u043e\u0431\u044a\u0435\u043a\u0442, \u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u043c \u0435\u0433\u043e \u043f\u043e\u043b\u044f \u0438 \u0441\u043e\u0445\u0440\u0430\u043d\u044f\u0435\u043c. \u0412 \u043a\u043e\u043d\u0441\u043e\u043b\u0438 \u043c\u043e\u0436\u0435\u0442\u0435 \u043d\u0430\u0431\u043b\u044e\u0434\u0430\u0442\u044c \u0440\u0430\u0434\u0443\u044e\u0449\u0438\u0435 \u0433\u043b\u0430\u0437 \u0441\u0442\u0440\u043e\u043a\u0438:<br \/>  <img decoding=\"async\" src=\"http:\/\/s1.ipicture.ru\/uploads\/20130826\/RiuX6Kxq.png\" alt=\"image\"\/><\/p>\n<p>  \u0422\u0430\u043a\u0441, \u043e\u0441\u0442\u0430\u043b\u043e\u0441\u044c \u0434\u043e\u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u0442\u0430\u0431\u043b\u0438\u0446\u044b \u043f\u0440\u0438 \u043e\u0431\u0440\u044b\u0432\u0435 \u0438\u043d\u0442\u0435\u0440\u043d\u0435\u0442 \u0441\u043e\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u044f. \u0412\u0435\u0441\u044c \u043a\u043e\u0434 \u043f\u043e\u0439\u0434\u0451\u0442 \u0432 \u043c\u0435\u0442\u043e\u0434 <code>- (void)VKRequest:(VKRequest *)request connectionErrorOccured:(NSError *)error<\/code> \u0438 \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u0433\u043b\u044f\u0434\u0435\u0442\u044c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c:  <\/p>\n<pre><code class=\"objectivec\">- (void)VKRequest:(VKRequest *)request         connectionErrorOccured:(NSError *)error { \/\/    \u043f\u043e\u043d\u0430\u0434\u043e\u0431\u0438\u0442\u0441\u044f \u043d\u0430\u043c \u0434\u043b\u044f \u0445\u0440\u0430\u043d\u0435\u043d\u0438\u044f \u0441\u043b\u043e\u0432\u0430\u0440\u0435\u0439 \u0441 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u0441\u043a\u043e\u0439 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0435\u0439     NSMutableArray *data = [[NSMutableArray alloc] init];  \/\/    \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0438\u0440\u0443\u0435\u043c \u0437\u0430\u043f\u0440\u043e\u0441 \u043d\u0430 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u0434\u0440\u0443\u0437\u0435\u0439     NSFetchRequest *fetchRequest = [[NSFetchRequest alloc]                                                     initWithEntityName:@&quot;Friend&quot;];     NSSortDescriptor *sortDescriptor = [NSSortDescriptor sortDescriptorWithKey:@&quot;last_name&quot;                                                                      ascending:YES];     [fetchRequest setSortDescriptors:@[sortDescriptor]];  \/\/    \u043e\u0441\u0443\u0449\u0435\u0441\u0442\u0432\u043b\u044f\u0435\u043c \u0437\u0430\u043f\u0440\u043e\u0441     NSArray *tmpData = [self.managedObjectContext executeFetchRequest:fetchRequest                                                                 error:nil];  \/\/    \u043e\u0431\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u0435\u043c \u0437\u0430\u043f\u0440\u043e\u0441     for(NSManagedObject *object in tmpData){ \/\/        \u044d\u0442\u0430 \u0441\u0442\u0440\u043e\u043a\u0430 \u0437\u0434\u0435\u0441\u044c \u043f\u043e\u0442\u043e\u043c\u0443, \u0447\u0442\u043e \u0443 \u043c\u0435\u043d\u044f \u0432 \u0434\u0440\u0443\u0437\u044c\u044f\u0445 \u0435\u0441\u0442\u044c \u0443\u0434\u0430\u043b\u0435\u043d\u043d\u044b\u0439 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c - \u043c\u0443\u0434\u0430\u043a :)         if([object valueForKey:@&quot;status&quot;] == nil)             continue;          NSDictionary *tmp = @{                 @&quot;last_name&quot;: [object valueForKey:@&quot;first_name&quot;],                 @&quot;first_name&quot;: [object valueForKey:@&quot;last_name&quot;],                 @&quot;photo&quot;: [object valueForKey:@&quot;photo&quot;],                 @&quot;status&quot;: [object valueForKey:@&quot;status&quot;]         };          [data addObject:tmp];     }  \/\/    \u0442\u0435\u043f\u0435\u0440\u044c \u0434\u0430\u043d\u043d\u044b\u0435 &quot;\u043f\u0435\u0440\u0435\u0431\u0440\u043e\u0441\u0438\u043c&quot; \u0432 \u043d\u0443\u0436\u043d\u044b\u0439 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440     ASAViewController *controller = (ASAViewController *)self.window.rootViewController;     controller.userFriends = data;     [controller.tableView reloadData]; } <\/code><\/pre>\n<p>  \u0418 \u043d\u0435\u0431\u043e\u043b\u044c\u0448\u0438\u0435 \u043a\u043e\u0440\u0440\u0435\u043a\u0442\u0438\u0432\u044b \u0432\u043d\u0435\u0441\u0442\u0438 \u043d\u0430\u0434\u043e \u0432 \u043c\u0435\u0442\u043e\u0434 <code>- (UITableViewCell *)tableView:(UITableView *)tableView   cellForRowAtIndexPath:(NSIndexPath *)indexPath<\/code>:  <\/p>\n<pre><code class=\"objectivec\">- (UITableViewCell *)tableView:(UITableView *)tableView   cellForRowAtIndexPath:(NSIndexPath *)indexPath {     static NSString *cellID = @&quot;friendID&quot;;      UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:cellID];     if(nil == cell){         cell = [[UITableViewCell alloc]                 initWithStyle:UITableViewCellStyleSubtitle               reuseIdentifier:cellID];     }      \/\/    setting default image while main photo is loading     cell.imageView.image = [UIImage imageNamed:@&quot;default.png&quot;];      dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_BACKGROUND, 0), ^{         NSData *img;          if([_userFriends[(NSUInteger) indexPath.row][@&quot;photo&quot;] isKindOfClass:[NSData class]]){             img = _userFriends[(NSUInteger) indexPath.row][@&quot;photo&quot;];         } else {             NSString* imgPath = _userFriends[(NSUInteger)indexPath.row][@&quot;photo&quot;];             img = [NSData dataWithContentsOfURL:[NSURL URLWithString:imgPath]];         }          dispatch_async(dispatch_get_main_queue(), ^{             cell.imageView.image = [UIImage imageWithData:img];         });     });      NSString* firstName = _userFriends[(NSUInteger)indexPath.row][@&quot;first_name&quot;];     NSString* lastName = _userFriends[(NSUInteger)indexPath.row][@&quot;last_name&quot;];     NSString* fullName = [NSString stringWithFormat:@&quot;%@ %@&quot;, firstName, lastName];     cell.textLabel.text = fullName;      NSString* status = _userFriends[(NSUInteger)indexPath.row][@&quot;status&quot;];     cell.detailTextLabel.text = status;      return cell; } <\/code><\/pre>\n<p>  \u0423\u0440\u0430! \u041f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u0437\u0430\u0432\u0435\u0440\u0448\u0435\u043d\u043e \u0438 \u0432\u044b\u0432\u043e\u0434\u0438\u0442 \u043e\u043d\u043e \u0434\u0440\u0443\u0437\u0435\u0439 \u0438\u0437 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0430:<br \/>  <img decoding=\"async\" src=\"http:\/\/s2.ipicture.ru\/uploads\/20130826\/vUhjXFM7.png\" alt=\"image\"\/><\/p>\n<h5>\u0421\u043b\u0451\u0437\u044b \u0440\u0430\u0434\u043e\u0441\u0442\u0438<\/h5>\n<p>  \u041d\u0430\u043a\u043e\u043d\u0435\u0446-\u0442\u043e \u043c\u044b \u0437\u0430\u043a\u043e\u043d\u0447\u0438\u043b\u0438 \u043d\u0430\u0448\u0443 \u043f\u0435\u0440\u0432\u0443\u044e, \u043d\u043e \u043d\u0435 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u044e\u044e \u043f\u0440\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u0443\u044e \u0447\u0430\u0441\u0442\u044c. \u0412\u0435\u0441\u044c \u043f\u0440\u043e\u0435\u043a\u0442 \u0412\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u043d\u0430\u0439\u0442\u0438 \u043f\u043e <a href=\"http:\/\/yadi.sk\/d\/RT0NyBzc8LXTw\">\u044d\u0442\u043e\u0439<\/a> \u0441\u0441\u044b\u043b\u043a\u0435 (\u043e\u043d \u0432 \u0430\u0440\u0445\u0438\u0432\u0435).<\/p>\n<p>  \u041d\u0430\u0434\u0435\u044e\u0441\u044c, \u0447\u0442\u043e \u0441\u043f\u0438\u043d\u0430 \u0438 \u043f\u0430\u043b\u044c\u0446\u044b \u043d\u0435 \u0443\u0441\u0442\u0430\u043b\u0438.<br \/>  \u041d\u0430\u0434\u0435\u044e\u0441\u044c, \u0447\u0442\u043e \u0412\u044b \u0434\u043e\u0432\u043e\u043b\u044c\u043d\u044b \u043f\u0440\u043e\u0432\u0435\u0434\u0435\u043d\u043d\u044b\u043c \u0432\u0440\u0435\u043c\u0435\u043d\u0435\u043c \u0432 \u043a\u043e\u043c\u043f\u0430\u043d\u0438\u0438 c Core Data.<br \/>  \u041d\u0430\u0434\u0435\u044e\u0441\u044c, \u0447\u0442\u043e \u0412\u044b \u0445\u043e\u0442\u0438\u0442\u0435 \u0432\u0438\u0434\u0435\u0442\u044c \u043f\u0440\u043e\u0434\u043e\u043b\u0436\u0435\u043d\u0438\u044f.<\/p>\n<h5>\u041f\u0440\u0438\u043c\u0435\u0447\u0430\u043d\u0438\u0435<\/h5>\n<p>  \u041d\u0438\u0447\u0442\u043e \u043d\u0435 \u043c\u043e\u0436\u0435\u0442 \u0440\u0430\u0434\u043e\u0432\u0430\u0442\u044c \u0430\u0432\u0442\u043e\u0440\u0430, \u043a\u0430\u043a \u043e\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u043d\u044b\u0439 \u043a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u0439, \u0434\u0430\u0436\u0435 \u0435\u0441\u043b\u0438 \u044d\u0442\u043e \u043a\u0440\u0438\u0442\u0438\u043a\u0430 \ud83d\ude09<\/p>\n<p>  \u0411\u043b\u0430\u0433\u043e\u0434\u0430\u0440\u044e \u0437\u0430 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435!    \t<\/p>\n<div class=\"clear\"><\/div>\n<\/p><\/div>\n<p> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"http:\/\/habrahabr.ru\/post\/191472\/\"> http:\/\/habrahabr.ru\/post\/191472\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<div class=\"content html_format\">   \t\u0425\u0430\u0431\u0440\u0430\u043b\u044e\u0434\u0438, \u0434\u043e\u0431\u0440\u044b\u0439 \u0434\u0435\u043d\u044c!<br \/>  \u0421\u0435\u0433\u043e\u0434\u043d\u044f \u0445\u043e\u0447\u0443 \u043d\u0430\u0447\u0430\u0442\u044c <b>\u0432\u043e\u043b\u044c\u043d\u044b\u0439<\/b> \u043f\u0435\u0440\u0435\u0432\u043e\u0434 \u043a\u043d\u0438\u0433\u0438 \u041c\u0438\u0445\u0430\u0435\u043b\u044f \u041f\u0440\u0438\u0432\u0430\u0442\u0430 \u0438 \u0420\u043e\u0431\u0435\u0440\u0442\u0430 \u0412\u0430\u0440\u043d\u0435\u0440\u0430 \u00abPro Core Data for iOS\u00bb, \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u043c\u043e\u0436\u0435\u0442\u0435 \u0441\u043a\u0430\u0447\u0430\u0442\u044c \u043f\u043e <a href=\"http:\/\/it-ebooks.info\/book\/1843\/\">\u044d\u0442\u043e\u0439<\/a> \u0441\u0441\u044b\u043b\u043a\u0435. \u041a\u0430\u0436\u0434\u0430\u044f \u0433\u043b\u0430\u0432\u0430 \u0431\u0443\u0434\u0435\u0442 \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0442\u044c \u0442\u0435\u043e\u0440\u0435\u0442\u0438\u0447\u0435\u0441\u043a\u0443\u044e \u0438 <b>\u043f\u0440\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u0443\u044e<\/b> \u0447\u0430\u0441\u0442\u044c.<\/p>\n<p>  <img decoding=\"async\" src=\"http:\/\/habr.habrastorage.org\/post_images\/884\/2d0\/182\/8842d018201f3945800282b64f1d7221.jpg\" alt=\"image\"\/><\/p>\n<p>  \u0421\u043e\u0434\u0435\u0440\u0436\u0430\u043d\u0438\u0435:  <\/p>\n<ul>\n<li> <a href=\"http:\/\/habrahabr.ru\/post\/191334\/\">\u0413\u043b\u0430\u0432\u0430 \u21161. \u041f\u0440\u0438\u0441\u0442\u0443\u043f\u0430\u0435\u043c<\/a> (\u041f\u0440\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u0430\u044f \u0447\u0430\u0441\u0442\u044c) <\/li>\n<li> \u0413\u043b\u0430\u0432\u0430 \u21162. \u0423\u0441\u0432\u0430\u0438\u0432\u0430\u0435\u043c Core Data<\/li>\n<li> \u0413\u043b\u0430\u0432\u0430 \u21163. \u0425\u0440\u0430\u043d\u0435\u043d\u0438\u0435 \u0434\u0430\u043d\u043d\u044b\u0445: SQLite \u0438 \u0434\u0440\u0443\u0433\u0438\u0435 \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u044b<\/li>\n<li> \u0413\u043b\u0430\u0432\u0430 \u21164. \u0421\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u043c\u043e\u0434\u0435\u043b\u0438 \u0434\u0430\u043d\u043d\u044b\u0445<\/li>\n<li> \u0413\u043b\u0430\u0432\u0430 \u21165. \u0420\u0430\u0431\u043e\u0442\u0430\u0435\u043c \u0441 \u043e\u0431\u044a\u0435\u043a\u0442\u0430\u043c\u0438 \u0434\u0430\u043d\u043d\u044b\u0445<\/li>\n<li> \u0413\u043b\u0430\u0432\u0430 \u21166. \u041e\u0431\u0440\u0430\u0431\u043e\u0442\u043a\u0430 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0438\u0440\u0443\u044e\u0449\u0438\u0445 \u043c\u043d\u043e\u0436\u0435\u0441\u0442\u0432<\/li>\n<li> \u0413\u043b\u0430\u0432\u0430 \u21167. \u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u0438 \u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u043e\u0439 \u043f\u0430\u043c\u044f\u0442\u0438<\/li>\n<li> \u0413\u043b\u0430\u0432\u0430 \u21168. \u0423\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0432\u0435\u0440\u0441\u0438\u044f\u043c\u0438 \u0438 \u043c\u0438\u0433\u0440\u0430\u0446\u0438\u0438<\/li>\n<li> \u0413\u043b\u0430\u0432\u0430 \u21169. \u0423\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0442\u0430\u0431\u043b\u0438\u0446\u0430\u043c\u0438 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c NSFetchedResultsController<\/li>\n<li> \u0413\u043b\u0430\u0432\u0430 \u211610. \u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 Core Data \u0432 \u043f\u0440\u043e\u0434\u0432\u0438\u043d\u0443\u0442\u044b\u0445 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f\u0445<\/li>\n<\/ul>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-191472","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/191472","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=191472"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/191472\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=191472"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=191472"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=191472"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}