Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Confused????????

Status
Not open for further replies.

pravindesai

Programmer
Jul 14, 2003
1
IN
I wondered by a very stupid question .Can u help me ?

For a simple java application if i can save the file with other than the class name and
i can run that with the class name then why can't i do that with the servlet?

Sorry if it seems a very stupid question

 
i think with jsp or servlet, it looks for an empty constructor - exactly of that classname. For instance, if you have a class called TestA.java, then the compiler will complain if you don't have a default constructor in there,
specifically:-

//default constructor
TestA(){
}

~za~
You can't bring back a dead thread!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top