• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Pass JSP input variables to an EJB.

 
steve dowdall
Ranch Hand
Posts: 36
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
Can someone explain to me a little on how I would go about capturing three variables, say , name,userid, and doctype from a JSP page and pass them to an EJB for processing. Kinda new to the JSP thingie...
Steve
 
Mike Curwen
Ranch Hand
Posts: 3695
IntelliJ IDE Java Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Here's a tutorial from Sun that uses a JavaBean as a facade (or is it proxy?) to an EJB. The JSP then uses the useBean methods.

You were talking about the other way around, from JSP -> EJB, but perhaps this will give you a starting point?
http://java.sun.com/j2ee/sdk_1.2.1/techdocs/guides/ejb/html/Client5.html#10649
 
Tim Holloway
Saloon Keeper
Pie
Posts: 18212
53
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Or you could cheat. http://www.mousetech.com/EJBWizard.html
I haven't formally announced it yet (or maybe that just did), but I've posted a new production release - 3.4.0. The EJBWizard is a template-based RAD generator for Enterprise JavaBeans. In addition to generating the core code for EJBs, it also creates prototype JSPs that access them.
There are 2 JSPs generated by the supplied templates - a detail view/edit bean which works in conjunction with a support class that probably will be rewritten to be JavaBean (it really already is, except for the packaging) and a collection view, which accesses the EJBs more directly.
The 3.4.0 release supports WebLogic 6.1 and (I HOPE!) now provides the templates for JBoss that were missing from earlier releases. It's available from the ftp.mousetech.com site.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic