Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

backtrack

  • Loading branch information...
commit c80fac50f9ee21e69682de77c4fd20855b6e6ce2 1 parent 997cb67
@tvillia authored
View
2  Restaurants/DetailViewController.h
@@ -7,6 +7,8 @@
#import <UIKit/UIKit.h>
#import "Restaurant.h"
+@class Review;
+
@interface DetailViewController : UIViewController
{
Restaurant* restaurant;
View
39 Restaurants/DetailViewController.m
@@ -20,46 +20,17 @@ @implementation DetailViewController
@synthesize star4;
@synthesize star5;
+- (Review*) findMostHelpfulReview
+{
+ return nil;
+}
+
#pragma mark - View lifecycle
- (void)viewDidLoad
{
[super viewDidLoad];
- restaurant = [[Restaurant alloc] init];
- restaurant.name = @"Pio Pio";
- restaurant.address = @"746 First Avenue\nNew York, NY 10128";
- restaurant.cuisineType = @"Peruvian";
- restaurant.yearOpened = 1995;
-
- Review* review1 = [[Review alloc] init];
- review1.text = @"What fab-u-lass chicken! We could eat it all day if we didn't have to stop to drink sangria!";
-// review1.reviewer = @"The Addams";
- review1.score = 5;
- review1.numberOfHelpfulRatings = 19;
- review1.numberOfUnhelpfulRatings = 8;
-
- Review* review2 = [[Review alloc] init];
- review2.text = @"I DONE POSTED ON DA INTARWEBS!";
-// review2.reviewer = @"Anonymous";
- review2.score = 1;
- review2.numberOfHelpfulRatings = 0;
- review2.numberOfUnhelpfulRatings = 45;
-
- Review* review3 = [[Review alloc] init];
- review3.text = @"Some of the best chicken I've ever eaten. A helpful tip: get some green (Aji) sauce to go, they sell it by the pint!";
- review3.reviewerName = @"Jim Carr";
- review3.score = 5;
- review3.numberOfHelpfulRatings = 28;
- review3.numberOfUnhelpfulRatings = 2;
-
- Review* review4 = [[Review alloc] init];
- review4.text = @"While the food is amazing, they often simply don't pick up the phone when ordering out!";
-// review4.reviewer = @"Paul";
- review4.score = 4;
- review4.numberOfHelpfulRatings = 14;
- review4.numberOfUnhelpfulRatings = 5;
-
NSArray* array = [[NSArray alloc] initWithObjects:review1, review2, review3, review4, nil];
NSArray* reviews = [restaurant reviews];
Please sign in to comment.
Something went wrong with that request. Please try again.