<jsp:useBean…> VS <bean:define…> in struts

Posted on 2005-05-05
Medium Priority
Last Modified: 2008-03-04

I am wondering differences between <jsp:useBean…> and <bean:define…> in struts.

Question by:dkim18
  • 2
LVL 29

Accepted Solution

bloodredsun earned 400 total points
ID: 13939665
From the docs: http://struts.apache.org/userGuide/struts-bean.html

The <bean:define> tag differs from <jsp:useBean> in several ways, including:

    * Unconditionally creates (or replaces) a bean under the specified identifier.
    * Can create a bean with the value returned by a property getter of a different bean (including properties referenced with a nested and/or indexed property name).
    * Can create a bean whose contents is a literal string (or the result of a runtime expression) specified by the value attribute.
    * Does not support nested content (such as <jsp:setProperty> tags) that are only executed if a bean was actually created.
LVL 16

Expert Comment

ID: 13941539

Why bloodredsun always be the first to answer? You have a lot of points already....just kidding :) hehehe.

However, thx bloodredsun to answer all my questions. I truly appreciate it :). You are truly excellent J2EE programmer.

LVL 29

Expert Comment

ID: 13943329
>>thx bloodredsun to answer all my questions. I truly appreciate it :). You are truly excellent J2EE programmer.

lol Dave, if you want to see  points machines look at arie and mick (aozarov and objects), they are guys who really know J2EE. Compared to them I'm just an amateur...

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This shares a stored procedure to retrieve permissions for a given user on the current database or across all databases on a server.
If anyone asked you to network diagram of the internet, it was drawn in the form of a fluffy cloud which further became known as cloud computing. Popularly cloud computing is defined as workloads that run over the internet in a commercial provider’s…
Despite its rising prevalence in the business world, "the cloud" is still misunderstood. Some companies still believe common misconceptions about lack of security in cloud solutions and many misuses of cloud storage options still occur every day. …
With just a little bit of  SQL and VBA, many doors open to cool things like synchronize a list box to display data relevant to other information on a form.  If you have never written code or looked at an SQL statement before, no problem! ...  give i…

829 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question