Hello,
I need to use a Factory pattern to create services class.
i have an interface --> MyService
i can have an abstract class --> MyAbstractServi ce
i have several concrete class for this service --> MyServiceVersio n1_1
MyServiceVersio n1_2.
I would like to create a factory which could instantiate object using
String (from XML file) as Class identifier. (maybe using a abstract
creator).
So that i'll be able to add some implementation class without rewritte
any lines on my code, only add concrete class to jar file and configure
XML file to use this.
example of a XML configuration file :
<IPNX>
<IPADDR>127.0.0 .1</IPADDR>
<COMPSERVICE>
<VERSION>1.1</VERSION>
<IMPL-SERVICE-CLASS>
ict.wtl.ipnx.se rvice.MyService Version1_1
</IMPL-SERVICE-CLASS>
</COMPSERVICE>
</IPNX>
Thank's
--
-------------------
Sebastien Degardin
Intercall-Telecom
Java - J2EE (beginner)
sdegardin@power devNOSPAM.be
I need to use a Factory pattern to create services class.
i have an interface --> MyService
i can have an abstract class --> MyAbstractServi ce
i have several concrete class for this service --> MyServiceVersio n1_1
MyServiceVersio n1_2.
I would like to create a factory which could instantiate object using
String (from XML file) as Class identifier. (maybe using a abstract
creator).
So that i'll be able to add some implementation class without rewritte
any lines on my code, only add concrete class to jar file and configure
XML file to use this.
example of a XML configuration file :
<IPNX>
<IPADDR>127.0.0 .1</IPADDR>
<COMPSERVICE>
<VERSION>1.1</VERSION>
<IMPL-SERVICE-CLASS>
ict.wtl.ipnx.se rvice.MyService Version1_1
</IMPL-SERVICE-CLASS>
</COMPSERVICE>
</IPNX>
Thank's
--
-------------------
Sebastien Degardin
Intercall-Telecom
Java - J2EE (beginner)
sdegardin@power devNOSPAM.be
Comment