![]() |
|||||||||||||||||
| |
|
|
|||||||||||||||
|
Application Control Points
public Application() {
1. Server startup When the application launches it constructs a single application object super(); /* ** Put your application initialization code here ** */ System.out.println("First step: Server starting up");} 2. Application Runs Waits for requests Serves requests from users via Top Page URL requests 3. Server shutdown When the application terminates, the last thing that happens is a call to terminate You can override terminate to include your cleanup code public void terminate() {/* ** Put your application shutdown code here ** */ System.out.println("Last step: Server shut down"); super.terminate();} NOTE: you should not call any code from other classes here
Page updated August 22, 2004
|
||||||||||||||||
|
|
|||||||||||||||||