tomcat-taglibs-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Robert Karen <robert_ka...@yahoo.com>
Subject beans vs. tags
Date Tue, 23 Jan 2001 20:36:59 GMT
Newbie design question:

In light of 'JSP is a view technology', how would
propose designing the following. Suppose you desire
a tag/component web designers can include to track
pages read by users and store it in a database.
Would you discourage tags and use beans exclusively,
or use a tag ie <tracking:InsertTrack page=page1.jsp>.
And if you had a number of different tags that used
the
same database, where would you place a connection
whose
instance could be shared?

Robert Karen

--- "Delagrange, Morgan" <mdelagra@us.britannica.com>
wrote:
> Hi Robert, Hi Jeff,
> 
> 
> Jeff, generally I agree that JSP is a view
> technology, but I don't see a
> good reason to restrict it to that.  In this
> particular example, if what you
> desire in your view closely matched the database
> contents, I don't see a
> compelling reason to push the model out to a Bean. 
> Many other
> template-based technologies use direct database
> connectivity to good effect.
> 
> - Morgan
> 
> 
> > -----Original Message-----
> > From: Ward, Jeff [mailto:jward@BenefitPoint.com]
> > Sent: Monday, January 22, 2001 3:23 PM
> > To: 'taglibs-user@jakarta.apache.org'
> > Subject: RE: sql tag lib.
> > 
> > 
> >   They are all inside of the page context that is
> passed into 
> > the tag on
> > init. Depending on what scope you declared the
> bean to be it 
> > will appear in
> > either the page, request, session or application
> scopes. If you use
> > PageContext.findAttribute() it will search all of
> them for you.
> > 
> >   Now, on another note.....
> > <soapbox>
> >   I have been noticing a lot of SQL libs and the
> like popping 
> > up and I was
> > wondering what other peoples opinions are of these
> functional type
> > libraries. To me, taglibs are a pure view
> technology. Things 
> > like sql tag
> > libs miss the point entirely and lead to the
> single layer web 
> > app with all
> > the maintenance nightmares that come with it.
> >   I'm just trying to get a feel for how people
> envision tag 
> > libs use and the
> > future of the things. Any thoughts?
> > </soapbox>
> >  
> >   -Jeff Ward
> > 
> >  -----Original Message-----
> > From: 	Robert Karen
> [mailto:robert_karen@yahoo.com] 
> > Sent:	Monday, January 22, 2001 12:17 PM
> > To:	taglibs-user@jakarta.apache.org
> > Subject:	sql tag lib.
> > 
> > I'm toying with writing a short tag lib
> > that would use a database connection.
> > How could I scope the connection at the
> application
> > or session and pass/access the connection instance
> in
> > the taglib instance? My thoughts were to have a
> > generic connection bean, but I don't know how to
> > get to it to the taglib. 
> > 
> > Thanks for any guidance.
> > 
> > Robert Karen
> > 
> > __________________________________________________
> > Do You Yahoo!?
> > Yahoo! Auctions - Buy the things you want at great
> prices. 
> > http://auctions.yahoo.com/
> > 
> 


__________________________________________________
Do You Yahoo!?
Yahoo! Auctions - Buy the things you want at great prices. 
http://auctions.yahoo.com/

Mime
View raw message