Person
struct- Attributes:
id
(Int)firstName
(String)lastName
(String)spouseID
(Optional Int)birthDate
(Date)parentIDs
(Array of Ints)maidenName
(Optional String)image
(UIImage)
- Attributes:
Family
Enum- Contains
familyMembers
array, containing the Person objects to make up the familyformatBirthDate
: helper method to return a date string based on the Date property in the given Person objectfindChildren
: helper method to return an array of Person objects who would be the children matching the given PersonfindSpouseName
: helper method to return the name of the spouse of a given Person object
- Contains
currentGeneration
- Array which will hold the members of the family to be displayed on the screen
greatGrandparent
Person
constant which will be the first level of the tree
- TableViewController for each of the 4 generations
- NavigationController embedded in first view controller
- Set up TableVeiwControllers for each of the 4 generations
- First generation will have a navigation controller embedded within it
- Create a segue for the prototype cell on each table view controller to link it to the next view
- Create a custom prototype cell to allow for additional data like the spouse name and birth date to be displayed in the cell
- When a cell is tapped, display the children of that person on the next screen