Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Tag Question

 
Chatura Dilan
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I want to know in Classic tags, what happen if a method returns a value if that method is not supposed to return that value

Example: what happen if doStartTag() returns SKIP_PAGE ?
what happen if doEndTag() returns SKIP_BODY ?
what happen if doStartTag() returns EVAL_BODY_AGAIN ?

according to me it will not lead to compilation error. can you explain it?

Thanks
 
Charles Lyons
Author
Ranch Hand
Posts: 836
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A quick search would lead you to this recent post which answers your question: classic tags.

And no - there is no compilation error since an int is an int... If the API had been written after Java SE 5, they'd probably be enums and would be type safe.
 
Chatura Dilan
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thanks Charles
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic