Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Trouble with the term "Standard Action"

 
JohnWilliam Fitz
Ranch Hand
Posts: 80
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi.

I'm having trouble defining to myself exactly what "Standard Action" means. Is it any tag of the format "<jsp:xxx />"? Is it limited to just those kinds of tags? Or are there standard actions that start with some other tag name?

Then, are "custom actions" a synonym for standard actions? Or a superset of standard actions? Or a subset of standard actions?

Thanks in advance,
John
 
Seetharaman Venkatasamy
Ranch Hand
Posts: 5575
Eclipse IDE Java Windows XP
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
have a look

Hope This Helps
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hope This Helps

The link you have provided is about JSTL, JSP Standard Tags Library. Standard actions refer to JSP's own tags, using the jsp prefix. There are listed in the JSP Specification, JSP.5 Standard Actions.
[ October 22, 2008: Message edited by: Christophe Verre ]
 
Adeel Ansari
Ranch Hand
Posts: 2874
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
For example, <jsp:usebean />
 
Seetharaman Venkatasamy
Ranch Hand
Posts: 5575
Eclipse IDE Java Windows XP
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Christophe Verre:
Standard actions refer to JSP's own tags, using the jsp prefix.


got it Christophe Verre. Thanks a lot
 
Jan Sterk
Ranch Hand
Posts: 142
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes this is very confusing stuff. Sun made a mess of the terminology.

There are
* standard actions
* custum tags
* standard tag library

In fact, they all belong to the category 'actions'. In the latest specs, custom tags are indeed called custom actions. This makes more sense, because the only difference between the two is that s.a. are actions that are defined in the specs, and that they are taken care of by the container without the need of importing anything.

The standard tag library consist of actions that do need importation. The difference with custom actions are that they are supplied by Sun. (And also that mentioned in the specs, but that I'm not sure). A more logical name for them would be 'standard custom actions', but that would just bring more cunfusion right now
 
Adeel Ansari
Ranch Hand
Posts: 2874
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Jan Sterk:
Yes this is very confusing stuff. Sun made a mess of the terminology.

There are
* standard actions
* custum tags
* standard tag library


Not really, just be more specific and short in some cases. Like

* JSP standard actions (A little larger but clear enough)
* Custom Tags (Its just fine)
* JSTL (Shorter and clear enough)

 
Jan Sterk
Ranch Hand
Posts: 142
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What's not clear for the beginner (that's the way I experienced it by reading HFSJ), is that all 3 belong to the same category: actions.
 
Adeel Ansari
Ranch Hand
Posts: 2874
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Jan Sterk:
What's not clear for the beginner (that's the way I experienced it by reading HFSJ), is that all 3 belong to the same category: actions.


I don't see 2nd and 3rd belong to actions. May be few folks argue for the 2nd, but 3rd clearly doesn't stand there.
 
Anton Golovin
Ranch Hand
Posts: 476
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Standard vs. custom means Sun-provided vs. written by you, that's for tags. Actions must be similar.
 
JohnWilliam Fitz
Ranch Hand
Posts: 80
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Christophe said: "Standard actions refer to JSP's own tags, using the jsp prefix. There are listed in the JSP Specification, JSP.5 Standard Actions."

Thanks for that Christophe. The definition in the spec is simple yet unambiguous. It says "Standard actions are represented using XML elements with a prefix of jsp (though that prefix can be redefined in the XML syntax)." I am slowly learning that the specs are actually the first place I should check to my answer my questions. )

But the term custom action and its relationship to standard actions is unclear? Are standard actions all custom actions?

Pardon my dead horse beating.

Thanks,
John
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Standard actions are actions "standardized" by the JSP specification, and prefixed with "jsp". Thus, they are not custom actions. Any other kind of actions are custom.
 
Charles Lyons
Author
Ranch Hand
Posts: 836
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Standard actions are actions "standardized" by the JSP specification
I think that basically hits the nail on the head. There is a large mix of terminology all over the place, and the terms "tag" and "action" are totally synonymous---in precisely the same way that (X)HTML has "tags" which are also XML "elements", and either terminology is well understood. What is important is that "standard" things are defined in the spec.*, while custom things are not. JSTL is a custom tag library, just a very well-known and -used one.


* This means containers can optimise the code quite significantly to avoid the overheads of importing libraries, instantiating handler instances and maintaining pools of handlers. Because JSTL is so common, newer containers which come bundled with JSTL actually do the same thing for that library too so you get the best performance. But that's all container-dependent anyway, and unimportant for SCWCD.
[ October 26, 2008: Message edited by: Charles Lyons ]
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic