Geeks Talk

Prepare for your Next Interview




System functions Vs Entity classes

This is a discussion on System functions Vs Entity classes within the Data Modeling forums, part of the Databases category; I have a confusion with entity classes. as far as I know entity classes are directly mapped to database entities (tables). I want to know in which classes business functions(...


Go Back   Geeks Talk > Databases > Data Modeling

Register FAQ Members List Calendar Mark Forums Read
  #1 (permalink)  
Old 07-18-2007
Contributing Member
 
Join Date: Sep 2006
Location: bangalore, india
Posts: 1,007
Thanks: 0
Thanked 71 Times in 60 Posts
psuresh1982 will become famous soon enough
System functions Vs Entity classes

I have a confusion with entity classes. as far as I know entity classes are directly mapped to database entities (tables). I want to know in which classes business functions(eg. in a Library System, reserveBook(),checkoutBook() so on...) should be implemented. Do I need to put business functions to a set of separate classes or can I keep them in relevant entity classes? Actually I want to know what the best & accepted (If any standard exists) way of doing it. I hope it'll be really helpful if I give you an example.

For the simplicity, let's say that we're designing a library system. I want to know in which class reserveBook() method should be implemented. In Book entity class or In Member(entity) class or In a separate class reserved for business functionalities such as Services.

Some people say that reserveBook() should be implemented in Book(entity) class because it's a function relevant to book entity. Some guys say that it should be implemented in Member(entity) class since it's a function of a library member. Others believe that method should be implemented in a separate class likes a Service in order to keep Book(entity) class as a pure entity class that is directly mapped to a database table.

I would be grateful If you can help me to solve my problem using this little example since it seems to be more effective.

---------------------
suresh
Reply With Quote
Sponsored Links
Reply

  Geeks Talk > Databases > Data Modeling


Thread Tools
Display Modes


Similar Threads

Thread Thread Starter Forum Replies Last Post
WireKeys is a hotkey-driven system utility that runs in the system tray and provides JobHelper Geeks Lounge 0 05-18-2007 01:20 PM
Entity Relationship Model Lokesh M Data Modeling 0 04-24-2007 06:21 AM
System Safety Monitor allows you to track down Microsoft Windows operating system act JobHelper Geeks Lounge 0 01-23-2007 11:31 AM
create new entity in crm 3.0 SIVAM_SOLAI Microsoft CRM 0 10-06-2006 12:35 AM
Microsoft CRM : Connect a new entity to an existing entity by using a lookup field Jim.Anderson Microsoft CRM 0 09-27-2006 06:39 AM


All times are GMT -4. The time now is 02:18 PM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0
Copyright © 2008 GeekInterview.com. All Rights Reserved