On 6/15/07, M. Bitner [EMAIL PROTECTED] wrote:
That got it working - thank you all so much for your help.
Turns out I was wrong, though, and it's the class attribute that has
to match up. Been awhile since I looked at that. Good that you
solved your problem, anyway.
-Dave
On 6/15/07,
On 6/14/07, M. Bitner [EMAIL PROTECTED] wrote:
bean id=AddStoryCardAction
action name=AddStoryCard
Your action name has to correspond to your bean id, so:
action name=AddStoryCardAction ...
or
bean id=AddStoryCard ...
HTH,
Dave
That got it working - thank you all so much for your help.
On 6/15/07, David Durham, Jr. [EMAIL PROTECTED] wrote:
On 6/14/07, M. Bitner [EMAIL PROTECTED] wrote:
bean id=AddStoryCardAction
action name=AddStoryCard
Your action name has to correspond to your bean id, so:
--- M. Bitner [EMAIL PROTECTED] wrote:
[...] Spring is picking up the beans defined in
applicationContext and instantiating them. How do I
get them into my actions to use them for data
access?
Two main ways:
1) Wire them up by hand (define your actions as beans
in a Spring context file, wire
Maybe http://struts.apache.org/2.x/docs/spring-plugin.html can be of some
help.
Cheers,
Peter
-Original Message-
From: Dave Newton [mailto:[EMAIL PROTECTED]
Sent: den 14 juni 2007 13:59
To: Struts Users Mailing List
Subject: Re: [S2] Getting DAO from Spring in Struts Action
--- M
On 6/14/07, Wesslan [EMAIL PROTECTED] wrote:
Maybe http://struts.apache.org/2.x/docs/spring-plugin.html can be of some
help.
You have to give your spring actions (those you want dependency
injection for) the same value for the name attribute as the value
you give for your spring bean's id
I really appreciate the input - I've been struggling with this for a
while. It's still not quite working though, and I'm sure the problem
is that there's something fundamental about the process that I don't
quite understand yet.
My applicationContext.xml looks like this:
?xml version=1.0
Good day,
I'm working on a Struts 2 app that uses Spring to manage the DAO
layer. I have the ContextLoaderListener and applicationContext
configured in web.xml. When the app starts I can see in the console
that Spring is picking up the beans defined in applicationContext and
instantiating them.
8 matches
Mail list logo