Peter Bell escreveu: > Hi Ronan, > > I'd strongly suggest using setter injection in > ColdSpring/Lightwire or your own custom factory to inject an object > with the methods yu need rather than calling an application scoped > util library. Otherwise stubbing/mocking it out for testing is going > to be more of a problem. >
Thank you Peter and Alan for the answer. Just let me talk more about it. In our actual project we (our team) defined to use Transfer ORM Objects as our beans. I mean: - Every time application calls serviceProduct.getBean(), DAOProduct.getBean() just answer transer.new( 'product.Product' ); - CRUD operations and some queries are done via TransferORM. It seemed a good option to save time and encapsulate and organize some logics. - Bean's set()'s method are defined into decorators, so every business logic that refers to Classes's Properties are inside the decorators; What do you think about it? Although it's a Transfer ORM subject, is there a way to inject external components into decorators? Thanks, Ronan --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "CFCDev" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cfcdev?hl=en -~----------~----~----~----~------~----~------~--~---
