Yeah you're right, Cakes models are DAOs. That is due to objects carrying a certain overhead in PHP (4), whereas they're virtually free in Ruby. There have been discussions about this before on the list. IIRC, Cake is slated to become OO by 2.0.
<nitpicking>I'd still say your question was aimed at (instance) methods accessing data stored in the model instance, rather than how to use instance methods.</nitpicking> Sorry, feeling nitpicky today. ;-) Chrs, Dav On 10 Oct 2008, at 10:41, cbankier wrote: > > Thanks for the reply. > > Actually "instance method" is exactly what I mean, as per > http://en.wikipedia.org/wiki/Instance_method > > I think my confusion is with the fact that cake Models can only return > arrays of data, not objects as I am used to from rails/Java. > > I guess the Model is really a DAO, not a domain object as I expected. >> It's more Cake-like to expect your data to be in an array that you > feed into functions > This seems more of a procedural approach rather than proper OO, but > I'll deal with that for now. > > > Still this helps me at understand how I need to structure my app to > fit in with cakes ways. > > Thanks, > Colin. > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~----------~----~----~----~------~----~------~--~---
