473,387 Members | 1,766 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

Servlet Design

Hello all,

Can someone point out a few servlet design patterns and general
observations when it comes to such development?
I'm familiar with the common one of having a servlet for every webpage,
but I'm trying to come up with a way of adding new webpages to an
existing servlet without having to worry about the servlet implementation
every time.

The way I'm thinking of implementing it is to have a class for every
webpage associated (not talking about the actual *html* code) with the
servlet and an interface which will define the way they interact.

So the servlet should have a HashMap with all the associated webpages and
each time will get the correct one depending on the request and use it.

This ofcourse is just something that I have in mind.
I'm trying to give food for thought here. :)
Thanks in advance,
Markos Charatzas
Jul 17 '05 #1
1 1908
See Jakarta Struts.

-Misk

Markos Charatzas wrote:
Hello all,

Can someone point out a few servlet design patterns and general
observations when it comes to such development?
I'm familiar with the common one of having a servlet for every webpage,
but I'm trying to come up with a way of adding new webpages to an
existing servlet without having to worry about the servlet
implementation every time.

The way I'm thinking of implementing it is to have a class for every
webpage associated (not talking about the actual *html* code) with the
servlet and an interface which will define the way they interact.

So the servlet should have a HashMap with all the associated webpages
and each time will get the correct one depending on the request and use it.

This ofcourse is just something that I have in mind.
I'm trying to give food for thought here. :)
Thanks in advance,
Markos Charatzas

--
================================================== ======================
Missaka Wijekoon (a.k.a. Misk) mw*******@RemoveThis.villageEdocs.com
Sr. Software Engineer http://www.villageEdocs.com
VillageEdocs
================================================== ======================
Jul 17 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Hai Tran | last post by:
Any help is appreciated. Installed Tomcat 4.1 and Mysql on a WinXP. I've manage to get Tomcat up and was able to view my first application ( myhome ) simple home page. Tomcat was installed under...
4
by: dave | last post by:
One thing i'm finding very quickly as my servlets become more logically condensed, is that an "object" in the sense of "object oriented design" becomes restricted to a "webpage/servlet". How do you...
1
by: sandeep patil | last post by:
my application design on java servlet i want to check password in python & return result again servlet to forward to next page. how to set session in python .get session
14
by: ramadeviirrigireddy | last post by:
Hi All, I have the following code for form and servlet. when the form is submitted the servlet will print the values passed by the form. i'm not getting the servlet o/p when i submit the...
0
by: krishna81m | last post by:
Could some one please explain why the session is not being maintained when I am doing a forward in a servlet after setting a cookie. I am even unable to set session attributes or parameters and...
6
by: Sushmita | last post by:
hi all, I have wrriten code for a small web application. From my JSP page i am not able to call the servlet.. its throwing an exception. "javax.servlet.ServletException: Wrapper cannot find...
1
by: shiyamala | last post by:
Hi i am shiyam, i am having some problem in java, i am basic java programmer. i have to write one program is writing the data into textfile name "newfile.txt" from one servlet and read it from...
9
by: mjahabarsadiq | last post by:
Hi I have created a servlet that is to be started at the server startup. And I got it. In that I have created a object of another class and set it as a session attribute. What I am trying is...
8
by: webster5u | last post by:
I'm design MVC structure for current developing system. Initially, the jsp will post data to servlet class. After processing, servlet will use the requestDispatcher to return processed data back to...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.