![]() |
Creating OOP classes in a right way - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23) +--- Thread: Creating OOP classes in a right way (/showthread.php?tid=36783) |
Creating OOP classes in a right way - El Forum - 12-14-2010 [eluser]Unknown[/eluser] Hello, My problem is how to right Create OOP classes in codeigniter For example: Code: Class forum{ So i need to have à class: forum 'has' topics 'has' reactions etc... Creating OOP classes in a right way - El Forum - 01-29-2011 [eluser].giorgio[/eluser] also for me this has been quite a problem... I'd like to write my code as much OOP as possible, for the sake of simplicity at the semantic level. I'd rather iterate through objects of, say, a Topic, than iterate through database results (although in the end the same result could be accomplished). I'm eagerly looking for a pattern to implement such a thing using codeigniter and Models (or don't I understand the model principle?). Especially for inheritence and abstraction Models don't suit my needs... How could i accomplish something like this? Code: abstract class Figure { |