One possible way is to wrap up your spring bean as an
Hivemind service 
(http://hivemind.apache.org/hivemind1/hivemind-lib/SpringLookupFactory.html).
Then inject that hivemind service into  your Tapestry
engine service.

Example : 
<service-point id="asoService"
interface="org.apache.tapestry.engine.IEngineService">
    <invoke-factory>
      <construct class="service.ASOService">
        <set-object property="exceptionReporter"
value="infrastructure:requestExceptionReporter"/>
        <set-object property="response"
value="infrastructure:response"/>
        <set-object property="linkFactory"
value="infrastructure:linkFactory"/>    
     <set-service property="entityService" 
                service-id="(service id of  the
hivemind service wrapper for your spring bean)"/>
      </construct>
    </invoke-factory>
  </service-point>
      
  
Shing
--- Nalin Gupta <[EMAIL PROTECTED]> wrote:

> Hi,
>  
> Is there any way to inject a Spring bean into an
> IEngineService (defined
> in hivemodule.xml) ? I tried to do this by using
> @InjectSpring
> (tapestry-spring), however I get a null pointer
> exception for the
> injected object.
>  
> @InjectSpring("entityService")
>  public EntityService getEntityService() {
>   return entityService;
>  }
>  
> getEntityService() returns null.
>  
> regards,
> Nalin.
>  
> 
> NOTICE
> This e-mail and any attachments are confidential and
> may contain copyright material of Macquarie Bank or
> third parties. If you are not the intended recipient
> of this email you should not read, print,
> re-transmit, store or act in reliance on this e-mail
> or any attachments, and should destroy all copies of
> them. Macquarie Bank does not guarantee the
> integrity of any emails or any attached files. The
> views or opinions expressed are the author's own and
> may not reflect the views or opinions of Macquarie
> Bank.
> 


Home page :
  http://uk.geocities.com/matmsh/index.html


                
___________________________________________________________ 
What kind of emailer are you? Find out today - get a free analysis of your 
email personality. Take the quiz at the Yahoo! Mail Championship. 
http://uk.rd.yahoo.com/evt=44106/*http://mail.yahoo.net/uk 

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to