Parent and Child things again.

For questions and postings not covered by the other forums
ConvertFromOldNGs
Posts: 5321
Joined: Wed Aug 05, 2009 5:19 pm

Re: Parent and Child things again.

Postby ConvertFromOldNGs » Fri Aug 07, 2009 11:51 am

by Torrie Moore >> Thu, 13 Apr 2000 4:23:20 GMT

In the case you have described I don't think you should use a parent child relationship. It sounds like a player can exist in many chatrooms in which case a many to many relationship is needed?
A parent child relationship is used where an object has no meaning without its parent. For example in a financial system a transaction has a collection of lines. These lines only have meaning when they have a parent ie a transaction. If the transaction is deleted then so should the lines. In your system it sounds like a player has meaning without a chatroom. In this case the relationship would be peer to peer and your code would handle deletion probably in one of the ways suggested by Darrell.

Torrie Moore
torrie@concept-eng.com

ConvertFromOldNGs
Posts: 5321
Joined: Wed Aug 05, 2009 5:19 pm

Re: Parent and Child things again.

Postby ConvertFromOldNGs » Fri Aug 07, 2009 11:51 am

by JADE Kid - Ray Hidayat >> Thu, 13 Apr 2000 5:58:57 GMT

No, 1 player, 1 chatroom. 1 chatroom, many players.


Return to “General Discussion”

Who is online

Users browsing this forum: No registered users and 25 guests