GithubHelp home page GithubHelp logo

ios-sprint-challenge-my-movies's Introduction

MyMovies

Instructions

Please read this entire README to make sure you understand what is expected of you before you begin.

In your solution, it is especially important that you follow best practices such as MVC and good, consistent code style. You will be scored on these aspects as well as the project requirements below.

Begin by forking this repository. Clone your forked repository to your machine. Use the provided Xcode project in the repository as it contains starter code. Commit as appropriate while you work. Push your final project to GitHub, then create a pull request back to this original repository.

You will have 3 hours to complete this sprint challenge

Good luck!

Requirements

This project uses The Movie DB API. The starter project has search functionality working for you already, as that isn't the point of this Sprint Challenge. There is no need to reference the API's documentation whatsoever.

The requirements for this project are as follows:

Data Modeling

  1. A Movie Core Data object. It should be comprised of the following attributes: identifier of type UUID, title of type String, and hasWatched of type Bool. You'll need to create a Core Data model file and set up your entity with the above attributes. Remember to consider things like Core Data optionality and default values for your attributes. You'll also need to create an extension to the Movie type so you can create convenience initializers for use elsewhere in the project.
  2. A MovieRepresentation object for sending data to/from Firebase. Its attributes should match the properties found in the Movie managed object (remember the UUID type isn't supported in JSON).
  3. The MovieController has already been set up to fetch data from TheMovieDB. You'll add more functionality to this class to perform syncing with Firebase as well as any other manipulation of your models you might need.

Changes to MovieSearchTableViewController

  1. Update the MovieSearchTableViewController's viewWillDisappear method to turn the movies that were selected by the user into managed objects and stored in Core Data. The search tableview has been set to allow for multiple cell selection, so the user just needs to tap which movies from the results they want to save.

Changes to MyMoviesTableViewController

  1. Display the list of saved movies in the MyMoviesTableViewController. You must use an NSFetchedResultsController to display the movies. Separate the movies into two sections in the table view by whether they have been watched or not.
  2. This table view's prototype cell should let the user update whether they have seen the movie or not. You will toggle the button on the right side of the cell between two different SF Symbols: "film" for unwatched, and "film.fill" for watched.

Firebase Syncing

  1. Send changes to the user's saved movies to a Firebase Database when creating, saving, and deleting movies. The database will be one you create in your own Firebase account.
  2. Synchronize the movies in Firebase with the device's local database in Core Data. Be sure to use a background NSManagedObjectContext where necessary to ensure Core Data concurrency is respected. Use the Core Data concurrency debug flag in your scheme to check your work (-com.apple.CoreData.ConcurrencyDebug 1).

ios-sprint-challenge-my-movies's People

Contributors

spencercurtis avatar bohdan462 avatar mredig avatar armadsen avatar jcgohlke avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.