File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

List attribute on Simple Tag Handler

 
stefania ferrarelli
Greenhorn
Posts: 29
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I try to make a List attribute on TLD of a Simple Tag but when I iterate over it, EL expressions show nothing.Any doubts:
-when I make the attribute I need to choose Object on netbeans :is it correct?


-is it correct to change the Object argument type of the default setter method to a List type ?


-the attribute is movieList but can I set another attribute - movie - on JspContext, regardless to TLD?


In general, can I set other attributes on JspContext() in addition to those declared on TLD? It is not clear to me what is my mistake...
Stefania

 
Frits Walraven
Creator of Enthuware JWS+ V6
Saloon Keeper
Pie
Posts: 2166
57
Android Chrome Eclipse IDE
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Stefania,

Let me try to give you an answer:
-when I make the attribute I need to choose Object on netbeans :is it correct?

You can make it work, but you should use the type you are using (i.e. java.util.List)
-the attribute is movieList but can I set another attribute - movie - on JspContext, regardless to TLD?

No, you can't.

This won't work:

Attribute name invalid for tag Simple5 according to TLD

You are not setting an attribute but filling the body of the tag.

Regards,
Frits
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic