[eluser]Dam1an[/eluser]
I would have the following main objects
- forum
- thread
- post
- user
With the following relationships
Forum
- Has many forums
- Has many threads
- Belongs to only one forum
Thread
- Has many posts
- Belongs to only one forum
Post
- Has one author
- Belongs to one thread
User
- Creates many posts
What does what
Forum:
Pretty much the same as you've got, put also would need parent, so you can nest forums
Thread:
Gets list of posts, add post to the end of the thread, get post count etc
Post:
Again, much the same as yours
User:
Get/set user details, post history, unread posts, settings etc
One thing I'll say about yours is, not sure if some of your set methods are really needed (you may have just added them when you put the get?)
Such as:
Forum.set_id
Post.set_id
Post.set_user_id
Post.set_date
The reason I say you don't need these, is cause they would be set in the contructor when you create that forum/post, and they don't really change, the only exception being post.date as it can be edited, but that'll be taken care of internally
You could also just use __get and __set if you want
If you want me to explain my points in more detail, then just ask, or contact me via PM