hivemind-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Liebig, Stefan " <Stefan.Lie...@compeople.de>
Subject Re: How to pass parameters to service constructor?
Date Tue, 16 Aug 2005 06:45:02 GMT
May be this way:
 
<service-point id="DAO">
   <invoke-factory>
      <contruct class="impl.DAOImpl">
         <object>service-property:DataSourceProvider:dataSource</object>
      </contruct>
   </invoke-factory>
</service-point>

see: http://jakarta.apache.org/hivemind/hivemind/BuilderFactory.html

________________________________

Von: Aleksej [mailto:aleksej@ivs.lt]
Gesendet: Di 16.08.2005 08:10
An: hivemind-user@jakarta.apache.org
Betreff: How to pass parameters to service constructor?



How to pass parameters to service constructor?
For example, I have service-point declared like this:
<service-point id="DAO">
   <invoke-factory>
      <contruct class="impl.DAOImpl">
         <set-object property="dataSource"
object="service-property:DataSourceProvider:dataSource"/>
      </contruct>
   </invoke-factory>
</service-point>

This code will create DAO service and will set it dataSource property
with value 'dataSource' from
'DataSourceProvider' service. I wonder, if there a way to pass
dataSource in DAOImpl constructor,
not in property?


---------------------------------------------------------------------
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