This week's book giveaway is in the Clojure forum.
We're giving away four copies of Clojure in Action and have Amit Rathore and Francis Avila on-line!
See this thread for details.
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How do I declare a bean that is a property of another bean?

 
Thomas Kennedy
Ranch Hand
Posts: 137
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In my view I have this


In my JSP I have this:


Of course I will replace the scriplet:


but it would be nice to do this instead:


How can I declare a bean that is itself a property of another bean?
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64185
83
IntelliJ IDE Java jQuery Mac Mac OS X
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I think it's needless, but you can simply create a new scoped variable for foo in your controller. Though I don't see what the advantage is. In fact, it becomes less clear when you do that. I'd simply keep the original references.
 
Paul Clapham
Sheriff
Pie
Posts: 20187
26
MySQL Database
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I don't know about "declare"... you could certainly put the Foo object into request scope in your controller code identified as "foo", and then you could use

in your JSP.
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic