Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

fergusjk

macrumors member
Original poster
Aug 23, 2010
44
0
Ayrshire Coast, Scotland
Hi,

I'm developing a tabbar app that has several views. I've created a few classes in my project, including a database connection class.

Currently the objects are created in the FirstViewController. I'm at the stage where I'm going to need to create getter methods in FirstViewController for the other views to access the handles to the objects. But I'm thinking they may be better moved to the appDelegate?

Is there a standard/preferred/easier way to access common objects from different views? i.e. initialise them in the appDelegate and use getter methods to access the handles or is there a more efficient way?

Thanks.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.