> as pointed out by jeffrey i could also pass in the services as needed
> but i think this approach will bloat the methods of my domain objects.
> have you used this approach on a big codebase? doesn't it have some
> negative effects on the expressiveness of the Domain Objects?
When some domain l
On Mon, 10 Dec 2007 20:01:49 -0200, Kristian Marinkovic
<[EMAIL PROTECTED]> wrote:
thank you all for your input...
Domain Objects sometimes (quite often:)) need other services
to meet their function.
In this cases, I create a controller class and put the method the
implements that functio
t; negative effects on the expressiveness of the Domain Objects?
>
> g,
> kris
>
> -----"Filip S. Adamsen" <[EMAIL PROTECTED]> schrieb: -
>
> An: Tapestry users
> Von: "Filip S. Adamsen" <[EMAIL PROTECTED]>
> Datum: 10.12.2007 09:08PM
> Th
thank you all for your input... Domain Objects sometimes (quite often:)) need other services to meet their function. if you retrieve your entities from say Hibernateyou can use the Tuplizer to inject any other services you need. You can also achieve this if you ALWAYS create your Domain Objects usi
I meant domain class, sorry.
Filip S. Adamsen skrev:
Oh, I wasn't talking about sticking it in a class. That'd be... ugh. No.
I meant to have some class, presumably a singleton, hold the Registry.
But certainly not a domain object. Never. Ever.
-Filip
Paul Cooley skrev:
It's better to have
Oh, I wasn't talking about sticking it in a class. That'd be... ugh. No.
I meant to have some class, presumably a singleton, hold the Registry.
But certainly not a domain object. Never. Ever.
-Filip
Paul Cooley skrev:
It's better to have a simple singleton factory to contain the registry.
Pl
It's better to have a simple singleton factory to contain the registry.
Plus if you were crazy enough to put it into a domain object as a reference
(or any service reference) you need to make sure it's marked as transient so
it will be ignored when serialization occurs for the domain object.
On De
Well, having a Registry instance in some class is what you would do if
you were to run Tapestry 5 IoC as part of a non-web application.
I guess you could subclass TapestryFilter and override the init method
to get a hold of the Registry for retrieval through a static getter,
although I'm not s
> is it possible to use tapestry-ioc to inject services into domain objects?
First, I don't think it's good practice to inject services into domain
objects. If some operation of domain object really needs to use a service,
you could pass a service instance to that specific method instead of
inject