Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trial
Christopher Higgins
Courses Plus Student 1,183 PointsHelp designing data model for app
Firstly a big thank you to Treehouse and Ben for these excellent videos. Been a great help to me.
I've made my first app, something to help with my current job, kitchen fitting. I occasionally have to build custom units with multiple shelves and this app calculates the gaps between shelves and gives the measurement to the center of each one from the top.
I've got a Calculator class which does the calculations.
A Board class which contains the height of the board, number and thickness of shelves. MainActivity creates a Board object from a couple of EditTexts when a Calculate button is pressed and passes it to a Calculator object.
And a GapList class which Calculator returns and contains the size of gap between each shelf and each one's distance to the top of the board and is used in MainActivity to add the values to a View.
How does this all sound? Anything I should change or tips?
Thanks Chris
Ben Deitch
Treehouse TeacherBen Deitch
Treehouse TeacherHey Chris! That all sounds great. I can't think of anything that should be changed off the top of my head. As long as it's able to figure out the gaps for you, then it sounds like the app is a success. Also, it's pretty cool that your first app was something that you can put to use!