Monday, 15 March 2010

ios - how much view controller redundancy -



ios - how much view controller redundancy -

my app works resource of "gifts"

users can add together gifts, see them in list, , click on 1 of them , see page devoted gift, can edit listing , variety of other actions.

meanwhile, users not add together gifts can still @ them, interaction options much more limited.

which improve alternative:

to have 2 specific , discrete view controllers, 1 viewing gift outsider , 1 editing/viewing gift owner or have on view controller, , accommodate both situations programmatically, substituting in different buttons

i leaning towards first 1 flexibility , clarity, wondering if there performance issues or other concerns note approach.

i depends bit on how want display gift's properties. if want show them in form based way (maybe table view simple labels) would fine utilize 1 view controller, can switch between editing , presentation mode.

from point want have nice design, maybe user interactions when presenting gift, might worth utilize separate view controllers, since editing , presenting becomes more distinct point.

in general question inquire how much code you'd have add together one view controller taking both tasks, only serve 1 of 2 tasks, if amount of code reaches threshold (which nobody can define yourself), should switch using separate view controllers.

ios design-patterns design model-view-controller uiviewcontroller

No comments:

Post a Comment