Eager to Code, Enjoy to Debug ~ Embark into Each Stage with Your Heart

Archive for the ‘JSP’ Category

Day 5 – JSP (Part II)

Posted by: Chyne on: March 7, 2009

• Some common pre-defined variables
- request
- response
- out (the writer object to send output)
- session (session are automatically created, use a directive to disable)
- application (allows storing of data that is shared by other servlets /or JSP)
• JSP page directives
- Affects the overall structure of the servlet that is generated from the JSP
- Format :
(i) <%@ directive attribute = “value”>
(ii) <%@ page import=”java.util.*”%>
(iii) <%@ page session=”false” autoflush=”false”%>
(iv) <%@ [...]

Tags:

Day 5 – JSP (Part I)

Posted by: Chyne on: March 7, 2009

• What is a JSP?
- HTML web page mixed with Java code to generate dynamically contents.
- Java code is enclosed in <%….%> tags
- Full access to Java programming language (but only Java code used for writing servlet is applicable)
- Automatically translated to Java servlet.
• Why JSP?
- More convenient to write than ‘println’
- No ‘web.xml’ config
- Promote separation between presentation and application logic
Note: Browser only [...]

Tags:

Compiling a JSP File

Posted by: Chyne on: March 25, 2008

When compiling a .jsp file, Tomcat will create a .java file before creating a class. If you want to check the java file, you can find the java file in this location:
Tomcat5.0workCatalinalocalhost\orgapachejsp


Friday’s Java Snack


In Java, "thread" means:

  • An instance of class java.lang.Thread
  • A thread of execution


An instance of Thread is just an object that has variables and methods, and lives and dies on the heap.
 
A thread of execution is an individual process that has its own call stack (one thread per call stack).

 

November 2009
M T W T F S S
« Oct    
 1
2345678
9101112131415
16171819202122
23242526272829
30  

Archives


  • Polprav: Hello from Russia! Can I quote a post in your blog with the link to you?
  • Alex: Huge Thanks! This bug has annoyed me for a long time.
  • Donnieboy: Just wanted to drop you a line to say, I enjoy reading your site. I thought about starting a blog myself but don't have the time. Oh well maybe one

StatCounter

free hit counters