Mahmoud-Abdelwahab / IPSAssignment

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

IPSAssignment

Features

  • Show list of lessons from remote
  • Show cachedlist when you are offline
  • When open app first time and you don't have internet connection show error view with the specified error [also there is pull to refresh so when the intnet back you can refresh without closing the app and re open it ]
  • Show lesson Details screen
  • When click downlaod button the video start downloading
  • During the downloading the progress appears indecate the acual video downlaoded bits
  • When click cancel download the downlaoding process terminated you can notice that also on xcode logs
  • When click on video open the video player with full options
  • Screen rotatation works well
  • Next lesson button show next lesson in the list [ when you reach the last lesson the next button disappears ]
  • The logic i followed when lauching the app i fetch lesson list from remote and save it in coredata First then fetch from code data, when open app seconde time i fetch from remote first then if there is any update [ i save the updated lessons only in coredata ] , when the app is offline i get fetch from coredata
  • Opening the video every time i open th video i chech [if it's cached ot not even if there is intenet connection] if cached open from cache if not open using intenet connection data , if the video not cached an no internet i show message please connect to intenet
  • Why i followed this logic : t

Framework used

  • Coredata for caching the data
  • AVFoundation and AVKit for opening the video view

Third party libraries

  • Just Kingfisher SPM for caching images

Code Style

  • I am implementing the lesson list swit MVVM-C and lesson details with just MVVM But i am using INPUT/OUTPUT to make the code more cleaner

Tests

  • lessons list view model, usecase, dataSources unite tests
  • lesson details vide model unite tests

API reference

Screenshots

simulator_screenshot_3828FE95-2171-4B2F-88A7-1E466B13F3E8 simulator_screenshot_1AE48E56-707C-466C-81F5-CA580D8137F9 simulator_screenshot_9A454DA8-42F6-401D-85BE-0D218E4D4B31 simulator_screenshot_0B236D1C-B9FB-47E1-AA1F-0AE648F97C5E simulator_screenshot_03922E25-27AD-4B71-8D8A-7FF0645694E6

https://ipsmedia.notion.site/iOS-Developer-Test-36ec3cda5f95461ea78897fed1b2d080

About


Languages

Language:Swift 100.0%