IMHO, i agree with Richard, it does seems best practise to "label" the class you're creating an instance.
Reusabilité of the interface is one, important but you could had that having a very explicit code is generally good practice... ServiceName allow you to be be very explicit, as the serviceName will generally be more clearer than the interface name.
Belaran
2005/6/16, Hensley, Richard <[EMAIL PROTECTED]>:
Glen,
It really depends on whether or not multiple services implementing the same
interface will be present in your registry. I personally, always specify a
service name because it seems like I end up reusing an interface with a new
implementation or an implementation with a different configuration, either
of which has a new name.
Richard
-----Original Message-----
From: Glen Stampoultzis [mailto: [EMAIL PROTECTED]]
Sent: Wednesday, June 15, 2005 4:55 PM
To: [email protected]
Subject: Calls to registry.getService()
I'm wondering which is better practice - calling
registry.getService(class) or registry.getService(serviceName, class)
?
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
--
Belaran,
"What'do'ya mean ?"
"As a moto, I just avoid meaning anything..."
