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

Exceptions in JSP

 
chikki singh chotala
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What is runtime exception and compile time exception in jsp
 
Senthil B Kumar
Ranch Hand
Posts: 160
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
When the user request for a JSP, it gets converted to a Servlet and this servlet is compilted and executed to give the output.

When your JSP has any syntax errors like the standard tag names are wrongly mentioned , or misspelling of keywords..etc.. , when compiling the converted Servlet, the compiler will give the compilation error.

but if its a kinda logical error, say you have instantiated an Object and at some situation it becomes nullyfied and you are trying to access its method now. this situation doesnt happens when you are compiling the code, it happens only when the code is executed, so these kind of errors are called RunTime exceptions, ie exceptions/errors occuring during runtime.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic