tomcat-taglibs-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jerome Jacobsen" <jerome.jacob...@gentootech.com>
Subject RE: Problem with "empty" key word on a collection.
Date Thu, 13 Feb 2003 16:22:37 GMT
Wow.  That is extremely unintuitive.  Why not work on a Collection (which
automatically gives you List)?

> -----Original Message-----
> From: Shawn Bayern [mailto:bayern@essentially.net]
> Sent: Thursday, February 13, 2003 11:13 AM
> To: Tag Libraries Users List
> Subject: Re: Problem with "empty" key word on a collection.
>
>
> On Thu, 13 Feb 2003, Leon Doud wrote:
>
> > It appears that the empty keyword doesn't always
> > function on a collection.  I must be missing something
> > obvious..
> >
> > The folder object contains a collection of "content".
> > The useBean tag isn't initializing the Folder object.
> > Its there so I can use scriptlet debugging code.
> >
> > What exactly does empty check to determine if a collection is empty or
> > not?  It looks like that "empty" is checking if the folder.content is
> > null or not, not if its size is zero.
> >
> > Folder.getContent() returns a type of java.util.Collection.
>
> The 'empty' operator is specified to work with java.util.List and
> java.util.Map (as well as arrays and strings), not java.util.Collection in
> general.
>
> --
> Shawn Bayern
> "JSTL in Action"   http://www.manning.com/bayern
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: taglibs-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: taglibs-user-help@jakarta.apache.org
>
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: taglibs-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: taglibs-user-help@jakarta.apache.org


Mime
View raw message