troubleshooting Question

OOP Question - How To implement certain methods in my object model

Avatar of posseke
possekeFlag for Cabo Verde asked on
ProgrammingVisual Basic.NET
3 Comments2 Solutions205 ViewsLast Modified:
I have a rather theoritical question concerning OOP.
I have my object model containing every single business object.
Every business object alsohas its own DAO object (Data Access Object) that controls the data manipulation.

Now I've come to the point that i need to create certain methods that use one of my business objects, but don't really fit anywhere in the existing objects I created.

For example:

Let's say I have an Business Object 'Order', which contains  all properties and calls to the DAO object for data manipulation (Load, Save, Delete).
Now I create a method 'createProductionOrder'. In the business logic of my case, a production order is divided in two; a transfer order and a production order. So I need to create two 'Orders' in this one method.

And this is why i'm confused: I cannot put this method in my 'Order' class because it creates two different types of Orders.

Should i implement a new pattern, or maybe a helper class of some sort? Please, any help is strongly appreciated!

Greetz, po$$e
ASKER CERTIFIED SOLUTION
Darren
Project Manager / Technical Lead

Our community of experts have been thoroughly vetted for their expertise and industry experience.

Join our community to see this answer!
Unlock 2 Answers and 3 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 2 Answers and 3 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros