hivemind-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jean-Francois Poilpret" <jfpoilp...@hcm.vnn.vn>
Subject RE: Inner classes as services
Date Sun, 17 Oct 2004 11:30:06 GMT
Sorry for the noise,

The problem was in my code (I forgot to declare the service implementation
class to be "static" inside the Test Case, which justified that Hivemind
could not find a no-arg constructor for it;-))

FYI, the following notation must be used in Hivemodule.xml:
	com.acme.Mytest$MyService

Cheers

-----Original Message-----
From: Jean-Francois Poilpret [mailto:jfpoilpret@hcm.vnn.vn] 
Sent: Sunday, October 17, 2004 6:14 PM
To: hivemind-user@jakarta.apache.org
Subject: Inner classes as services

Hi all,

I am currently writing test cases for a service factory, and in order to
have a self-contained test case, I have defined a fake service interface and
a fake service implementation class as inner classes inside my test case
(with public access).

Then when I try to instantiate my service (through the Registry), I have an
exception telling that no constructor could be found for my fake service
implementation class.

In the hivemodule.xml, I tried both class names:
	com.acme.MyTest.MyService
	com.acme.Mytest$MyService
But both exhibit the same behavior.

Is this an unhandled situation in HiveMind, or is there a "trick" to make it
work?

Finally I had to create my fake interface and implementation as separate
files and of course everything is OK then, but it is not very good to
separate those from the Test Case.

Cheers




---------------------------------------------------------------------
To unsubscribe, e-mail: hivemind-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: hivemind-user-help@jakarta.apache.org




---------------------------------------------------------------------
To unsubscribe, e-mail: hivemind-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: hivemind-user-help@jakarta.apache.org


Mime
View raw message