Skip to content

Instantly share code, notes, and snippets.

@nalindz
Created December 5, 2012 08:20
Show Gist options
  • Save nalindz/4213764 to your computer and use it in GitHub Desktop.
Save nalindz/4213764 to your computer and use it in GitHub Desktop.
int i;
while (i < 1000) {
Page *newPage = [[Page alloc] initWithEntity:[Page entity] insertIntoManagedObjectContext:[NSManagedObjectContext contextForCurrentThread]];
newPage.page_number = [currentPageNumber copy];
newPage.story_id = self.story.id;
//newPage.text = [pageBuffer substringToIndex:splitIndex];
newPage.text = @"meowCAT";
newPage.first_block_number = [startBlockNumber copy];
newPage.first_block_index = [NSNumber numberWithInt:startBlockIndex];
newPage.last_block_number = [currentBlock.block_number copy];
i++;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment