Expert |
 |
Joined: Tue Nov 23, 2004 7:00 pm Posts: 570 Location: mostly Frankfurt Germany
|
Hello,
you could take a different approach.
Define state as a component holding an identifier.
Your state Class could call a factory depending on the value of the field. So the method of your State class does not implement the behaviour itself but call the Logic class generated by the factory.
Please rate, if this helped.
Regards Sebastian
_________________ Best Regards
Sebastian
---
Training for Hibernate and Java Persistence
Tutorials for Hibernate, Spring, EJB, JSF...
eBook: Hibernate 3 - DeveloperGuide
Paper book: Hibernate 3 - Das Praxisbuch
http://www.laliluna.de
|
|